|
2 | 2 | from springpython.context import * |
3 | 3 | from springpython.config import * |
4 | 4 |
|
5 | | -class UnicodeTestCase(unittest.TestCase): |
| 5 | +class UnicodeTestCaseXml(unittest.TestCase): |
6 | 6 | def testParsingAppContextWithNonAscii1(self): |
7 | 7 | ctx = ApplicationContext(XMLConfig("support/unicodeContext1.xml")) |
8 | 8 |
|
@@ -36,3 +36,36 @@ def testParsingAppContextWithNonAscii10(self): |
36 | 36 | self.fail("Expected an encoding error since Python code is ASCII based.") |
37 | 37 | except UnicodeEncodeError: |
38 | 38 | pass |
| 39 | + |
| 40 | +class UnicodeTestCaseYaml(unittest.TestCase): |
| 41 | + def testParsingAppContextWithNonAscii1(self): |
| 42 | + ctx = ApplicationContext(YamlConfig("support/unicodeContext1.yaml")) |
| 43 | + |
| 44 | + def testParsingAppContextWithNonAscii3(self): |
| 45 | + ctx = ApplicationContext(YamlConfig("support/unicodeContext3.yaml")) |
| 46 | + |
| 47 | + def testParsingAppContextWithNonAscii4(self): |
| 48 | + ctx = ApplicationContext(YamlConfig("support/unicodeContext4.yaml")) |
| 49 | + |
| 50 | + def testParsingAppContextWithNonAscii5(self): |
| 51 | + ctx = ApplicationContext(YamlConfig("support/unicodeContext5.yaml")) |
| 52 | + |
| 53 | + |
| 54 | + def testParsingAppContextWithNonAscii6(self): |
| 55 | + ctx = ApplicationContext(YamlConfig("support/unicodeContext6.yaml")) |
| 56 | + |
| 57 | + def testParsingAppContextWithNonAscii7(self): |
| 58 | + ctx = ApplicationContext(YamlConfig("support/unicodeContext7.yaml")) |
| 59 | + |
| 60 | + def testParsingAppContextWithNonAscii8(self): |
| 61 | + ctx = ApplicationContext(YamlConfig("support/unicodeContext8.yaml")) |
| 62 | + |
| 63 | + def testParsingAppContextWithNonAscii9(self): |
| 64 | + ctx = ApplicationContext(YamlConfig("support/unicodeContext9.yaml")) |
| 65 | + |
| 66 | + def testParsingAppContextWithNonAscii10(self): |
| 67 | + try: |
| 68 | + ctx = ApplicationContext(YamlConfig("support/unicodeContext10.yaml")) |
| 69 | + self.fail("Expected an encoding error since Python code is ASCII based.") |
| 70 | + except UnicodeEncodeError: |
| 71 | + pass |
0 commit comments