diff options
Diffstat (limited to 'yarnhelper_tests.py')
-rw-r--r-- | yarnhelper_tests.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/yarnhelper_tests.py b/yarnhelper_tests.py index 756a165..858bcdc 100644 --- a/yarnhelper_tests.py +++ b/yarnhelper_tests.py @@ -66,12 +66,9 @@ class PersistentVariableTests(unittest.TestCase): if os.path.exists(yarnhelper.variables_filename): os.remove(yarnhelper.variables_filename) - def test_raises_error_if_no_such_variable(self): + def test_returns_default_if_no_such_variable(self): h = yarnhelper.YarnHelper() - with self.assertRaises(yarnhelper.Error): - h.get_variable('FOO') - print - print 'variables:', h._variables + self.assertEqual(h.get_variable('foo', default=42), 42) def test_sets_variable_persistently(self): h = yarnhelper.YarnHelper() |