We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d1e7a5c commit 92562c2Copy full SHA for 92562c2
1 file changed
tests/integration/test_unit.py
@@ -280,3 +280,19 @@ async def test_subordinate_units(event_loop):
280
assert n_unit.principal_unit == 'ubuntu/0'
281
assert u_unit.principal_unit == ''
282
assert [u.name for u in u_unit.get_subordinates()] == [n_unit.name]
283
+
284
285
+@base.bootstrapped
286
+async def test_destroy_unit(event_loop):
287
+ async with base.CleanModel() as model:
288
+ app = await model.deploy(
289
+ 'juju-qa-test',
290
+ application_name='test',
291
+ num_units=3,
292
+ )
293
+ # wait for the units to come up
294
+ await model.block_until(lambda: app.units, timeout=480)
295
296
+ await app.units[0].destroy()
297
+ await asyncio.sleep(5)
298
+ assert len(app.units) == 2
0 commit comments