Skip to content

Commit 5337f5d

Browse files
Wait for exact number of units after scale down (#565)
Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
1 parent e0d7976 commit 5337f5d

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

tests/integration/ha_tests/test_async_replication.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -476,7 +476,11 @@ async def test_async_replication_failover_in_main_cluster(
476476
async with ops_test.fast_forward(FAST_INTERVAL), fast_forward(second_model, FAST_INTERVAL):
477477
await gather(
478478
first_model.wait_for_idle(
479-
apps=[DATABASE_APP_NAME], status="active", idle_period=IDLE_PERIOD, timeout=TIMEOUT
479+
apps=[DATABASE_APP_NAME],
480+
status="active",
481+
idle_period=IDLE_PERIOD,
482+
timeout=TIMEOUT,
483+
wait_for_exact_units=(CLUSTER_SIZE - 1),
480484
),
481485
second_model.wait_for_idle(
482486
apps=[DATABASE_APP_NAME], status="active", idle_period=IDLE_PERIOD, timeout=TIMEOUT

0 commit comments

Comments
 (0)