Test a refused connection's reason, an indented comment and a value between letters

This commit is contained in:
2026-11-14 19:59:07 +01:00
parent 8e6b2f1f12
commit 3931eef451
2 changed files with 9 additions and 4 deletions
+1 -1
View File
@@ -43,7 +43,7 @@ class ReadEnv(unittest.TestCase):
self.assertTrue(isinstance(failed, Failure) and failed.reason.startswith(f"cannot read {self.path}: "), failed)
def test_parses_quotes_comments_and_spaces(self):
self.assertEqual(parse_env("# note\nA = 1 \nB=\"two words\"\nC='3'\nnot a pair\n#D=4\nE=a=b\nF=\"\"\nG='\n"), {"A": "1", "B": "two words", "C": "3", "E": "a=b", "F": "", "G": "'"})
self.assertEqual(parse_env("# note\nA = 1 \nB=\"two words\"\nC='3'\nnot a pair\n#D=4\nE=a=b\nF=\"\"\nG='\n # H=5\nI=XaX\n"), {"A": "1", "B": "two words", "C": "3", "E": "a=b", "F": "", "G": "'", "I": "XaX"})
if __name__ == "__main__":