Sat Dec 12 01:53:33 2009 +0900
add unit test
| test/test_pyrg.py | file | annotate | diff | revisions |
1.1 --- a/test/test_pyrg.py Sun Dec 06 22:49:18 2009 +0900 1.2 +++ b/test/test_pyrg.py Sat Dec 12 01:53:33 2009 +0900 1.3 @@ -346,6 +346,20 @@ 1.4 self.assertEqual(pyrg.PRINT_COLOR_SET_DEFAULT, color_set) 1.5 temp.close() 1.6 1.7 + def test_config_keyword_notexist_2(self): 1.8 + config_example = """ 1.9 +[color] 1.10 +ok = 1.11 +fail = 1.12 +function = 1.13 +""" 1.14 + temp = NamedTemporaryFile() 1.15 + temp.file.write(config_example) 1.16 + temp.file.flush() 1.17 + color_set = pyrg.set_configuration(temp.name) 1.18 + self.assertEqual(pyrg.PRINT_COLOR_SET_DEFAULT, color_set) 1.19 + temp.close() 1.20 + 1.21 def test_config_keyword_notexist_4(self): 1.22 config_example = """ 1.23 [color]