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 | 335aa02cd95352581d08578ad6d9009c2db12d1b (patch) | |
tree | a8c50a6657485f19dec7c6c26a3bf74534bf04e6 /test/test_codeunit.py | |
parent | 97292be9173e455a4f9ceefcb1e0dd1bae13ad4f (diff) | |
download | python-coveragepy-git-335aa02cd95352581d08578ad6d9009c2db12d1b.tar.gz |
This wasn't testing code unit comparisons directly. Now it is.
Diffstat (limited to 'test/test_codeunit.py')
-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 ad073827..35387ba3 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 |