diff options
author | Scott Moser <smoser@ubuntu.com> | 2016-03-04 01:55:28 -0500 |
---|---|---|
committer | Scott Moser <smoser@ubuntu.com> | 2016-03-04 01:55:28 -0500 |
commit | 1a9a408a7bf6d7a1a06254ad2939bd549acba69b (patch) | |
tree | ec4f76ea5260e269c83addbfafa4376ea2678059 /tests/unittests/test_handler/test_handler_power_state.py | |
parent | bbf105baafbe788f7babbda188b513180424e256 (diff) | |
parent | 8092805079d011093724d87e9485e5bf79479a72 (diff) | |
download | vyos-cloud-init-1a9a408a7bf6d7a1a06254ad2939bd549acba69b.tar.gz vyos-cloud-init-1a9a408a7bf6d7a1a06254ad2939bd549acba69b.zip |
merge with trunk
Diffstat (limited to 'tests/unittests/test_handler/test_handler_power_state.py')
-rw-r--r-- | tests/unittests/test_handler/test_handler_power_state.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/tests/unittests/test_handler/test_handler_power_state.py b/tests/unittests/test_handler/test_handler_power_state.py index 5687b10d..04ce5687 100644 --- a/tests/unittests/test_handler/test_handler_power_state.py +++ b/tests/unittests/test_handler/test_handler_power_state.py @@ -74,7 +74,7 @@ class TestLoadPowerState(t_help.TestCase): class TestCheckCondition(t_help.TestCase): def cmd_with_exit(self, rc): return([sys.executable, '-c', 'import sys; sys.exit(%s)' % rc]) - + def test_true_is_true(self): self.assertEqual(psc.check_condition(True), True) @@ -94,7 +94,6 @@ class TestCheckCondition(t_help.TestCase): self.assertEqual(mocklog.warn.call_count, 1) - def check_lps_ret(psc_return, mode=None): if len(psc_return) != 3: raise TypeError("length returned = %d" % len(psc_return)) @@ -107,7 +106,7 @@ def check_lps_ret(psc_return, mode=None): if 'shutdown' not in psc_return[0][0]: errs.append("string 'shutdown' not in cmd") - if 'condition' is None: + if condition is None: errs.append("condition was not returned") if mode is not None: |