diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2009-12-18 20:46:40 -0500 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2009-12-18 20:46:40 -0500 |
commit | 19f7fc31e36efedfa207e4ac96b7e57fb0ac167b (patch) | |
tree | e84ff2ab03c8b821794be6cc36e8d0e6fcdfb268 | |
parent | 33dc1620c339e3af9446a97d4a17ccadad81c682 (diff) | |
download | python-coveragepy-19f7fc31e36efedfa207e4ac96b7e57fb0ac167b.tar.gz |
This wasn't testing code unit comparisons directly. Now it is.
-rw-r--r-- | test/test_codeunit.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/test_codeunit.py b/test/test_codeunit.py index ad07382..35387ba 100644 --- a/test/test_codeunit.py +++ b/test/test_codeunit.py @@ -64,10 +64,10 @@ class CodeUnitTest(CoverageTest): self.assertEqual(cu[2].source_file().read(), "# cfile.py\n") def test_comparison(self): - acu = code_unit_factory("aa/afile.py", FileLocator()) - acu2 = code_unit_factory("aa/afile.py", FileLocator()) - zcu = code_unit_factory("aa/zfile.py", FileLocator()) - bcu = code_unit_factory("aa/bb/bfile.py", FileLocator()) + acu = code_unit_factory("aa/afile.py", FileLocator())[0] + acu2 = code_unit_factory("aa/afile.py", FileLocator())[0] + zcu = code_unit_factory("aa/zfile.py", FileLocator())[0] + bcu = code_unit_factory("aa/bb/bfile.py", FileLocator())[0] assert acu == acu2 and acu <= acu2 and acu >= acu2 assert acu < zcu and acu <= zcu and acu != zcu assert zcu > acu and zcu >= acu and zcu != acu |