(self)
| 753 | self.assertRaises(RecursionError, run_path, zip_name) |
| 754 | |
| 755 | def test_encoding(self): |
| 756 | with temp_dir() as script_dir: |
| 757 | filename = os.path.join(script_dir, 'script.py') |
| 758 | with open(filename, 'w', encoding='latin1') as f: |
| 759 | f.write(""" |
| 760 | #coding:latin1 |
| 761 | s = "non-ASCII: h\xe9" |
| 762 | """) |
| 763 | result = run_path(filename) |
| 764 | self.assertEqual(result['s'], "non-ASCII: h\xe9") |
| 765 | |
| 766 | |
| 767 | @force_not_colorized_test_class |