Mercurial > hgrepos > Python > libs > ConfigMix
diff tests/test.py @ 502:4f90e1eb7af8
Make quote() and unquote() module globals and also export from configmix
| author | Franz Glasner <fzglas.hg@dom66.de> |
|---|---|
| date | Sat, 18 Dec 2021 01:26:41 +0100 |
| parents | a9a291927a4b |
| children | dffa692751b1 |
line wrap: on
line diff
--- a/tests/test.py Sat Dec 18 01:26:13 2021 +0100 +++ b/tests/test.py Sat Dec 18 01:26:41 2021 +0100 @@ -1207,16 +1207,16 @@ def test_quoting_and_unquoting_are_inverse(self): for c in """%.:#|"'{}[]""": - qc = self._cfg.quote(c) + qc = configmix.quote(c) self.assertTrue(qc.startswith("%x") and len(qc) == 4) - self.assertEqual(c, self._cfg.unquote(qc)) + self.assertEqual(c, configmix.unquote(qc)) def test_quoting_and_unquoting_are_identical(self): # other characters for c in """abc09/""": - qc = self._cfg.quote(c) + qc = configmix.quote(c) self.assertEqual(c, qc) - self.assertEqual(c, self._cfg.unquote(qc)) + self.assertEqual(c, configmix.unquote(qc)) def test_namespace_quoting(self): v1 = self._cfg.getvar("PY:version")
