mirror of
https://github.com/dragonflydb/dragonfly.git
synced 2025-05-10 18:05:44 +02:00
test: move ReplicaofRejectOnLoad test from pytest into unit tests (#4410)
This commit is contained in:
parent
21fcf5808e
commit
ed1436bb29
1 changed files with 8 additions and 0 deletions
|
@ -821,6 +821,14 @@ TEST_F(DflyEngineTest, StreamMemInfo) {
|
|||
EXPECT_GT(stream_mem_second, 0);
|
||||
}
|
||||
|
||||
TEST_F(DflyEngineTest, ReplicaofRejectOnLoad) {
|
||||
service_->SwitchState(GlobalState::ACTIVE, GlobalState::LOADING);
|
||||
|
||||
RespExpr res = Run({"REPLICAOF", "localhost", "3779"});
|
||||
|
||||
ASSERT_THAT(res, ErrArg("LOADING Dragonfly is loading the dataset in memory"));
|
||||
}
|
||||
|
||||
// TODO: to test transactions with a single shard since then all transactions become local.
|
||||
// To consider having a parameter in dragonfly engine controlling number of shards
|
||||
// unconditionally from number of cpus. TO TEST BLPOP under multi for single/multi argument case.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue