def test_that_patches_were_installed_on(node):
line = '0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded'
with settings(
hide('stdout', 'running'),
host_string=node.host_string,
private_key_filename=node.private_key
):
print(" running on %s" % node.host_string)
cmd = sudo('apt-get -u upgrade --assume-no')
try:
assert line in cmd.stdout
except Exception as detail:
raise Exception("%s %s" % (cmd.stdout, detail))
try:
assert cmd.return_code == 0
except Exception as detail:
raise Exception("%s %s" % (cmd.return_code, detail))
评论列表
文章目录