From 3670c2cdb732d378ba6d38e72e7cd875ff726aa9 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Sun, 14 Oct 2018 21:11:41 -0500 Subject: move tests out of the package --- tests/test_scripts/test_common.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 tests/test_scripts/test_common.py (limited to 'tests/test_scripts/test_common.py') diff --git a/tests/test_scripts/test_common.py b/tests/test_scripts/test_common.py new file mode 100644 index 000000000..60741db92 --- /dev/null +++ b/tests/test_scripts/test_common.py @@ -0,0 +1,13 @@ +import unittest + +class TestParseVars(unittest.TestCase): + def test_parse_vars_good(self): + from pyramid.scripts.common import parse_vars + vars = ['a=1', 'b=2'] + result = parse_vars(vars) + self.assertEqual(result, {'a': '1', 'b': '2'}) + + def test_parse_vars_bad(self): + from pyramid.scripts.common import parse_vars + vars = ['a'] + self.assertRaises(ValueError, parse_vars, vars) -- cgit v1.2.3