diff options
| author | Chris McDonough <chrism@agendaless.com> | 2009-01-11 22:43:27 +0000 |
|---|---|---|
| committer | Chris McDonough <chrism@agendaless.com> | 2009-01-11 22:43:27 +0000 |
| commit | b0a24149ffc4dd3b945b496e5cdb01111c8cf29a (patch) | |
| tree | da0d31fa9c46eb4e990c0df3dd116e8fa38dcd5c /repoze/bfg/tests/test_testing.py | |
| parent | d69635eb6237055e8b3ccedeeaa7114a7beed057 (diff) | |
| download | pyramid-b0a24149ffc4dd3b945b496e5cdb01111c8cf29a.tar.gz pyramid-b0a24149ffc4dd3b945b496e5cdb01111c8cf29a.tar.bz2 pyramid-b0a24149ffc4dd3b945b496e5cdb01111c8cf29a.zip | |
- Improve test coverage.
- Remove old cold which attempts to recover from trying to unpickle a
``z3c.pt`` template; Chameleon has been the templating engine for a
good long time now. Running repoze.bfg against a sandbox that has
pickled ``z3c.pt`` templates it will now just fail with an
unpickling error, but can be fixed by deleting the template cache
files.
Diffstat (limited to 'repoze/bfg/tests/test_testing.py')
| -rw-r--r-- | repoze/bfg/tests/test_testing.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/repoze/bfg/tests/test_testing.py b/repoze/bfg/tests/test_testing.py index 38d41be06..a92e340fc 100644 --- a/repoze/bfg/tests/test_testing.py +++ b/repoze/bfg/tests/test_testing.py @@ -311,7 +311,7 @@ class TestDummyModel(unittest.TestCase): self.assertEqual(clone.__parent__, 'parent2') self.assertEqual(clone.foo, 1) - def test_keys_items_values(self): + def test_keys_items_values_len(self): class Dummy: pass model = self._makeOne() @@ -320,6 +320,11 @@ class TestDummyModel(unittest.TestCase): self.assertEqual(model.values(), model.subs.values()) self.assertEqual(model.items(), model.subs.items()) self.assertEqual(model.keys(), model.subs.keys()) + self.assertEqual(len(model), 2) + + def test_nonzero(self): + model = self._makeOne() + self.assertEqual(model.__nonzero__(), True) class TestDummyRequest(unittest.TestCase): def _getTargetClass(self): |
