[TIP] figleaf tests

C. Titus Brown ctb at msu.edu
Mon Jun 23 17:11:35 PDT 2008


On Tue, Jun 24, 2008 at 01:43:40AM +0200, Ondrej Certik wrote:
-> I think we need tests in a form of code snippets and corresponding
-> numbers of all lines that can be executed and this will be checked
-> against the LineGrabber class.

Hi, Ondrej,

% find figleaf/tests -name \*.py
tests/__init__.py
tests/test-bin-progs/tst-cover.py
tests/test-bin-progs/utils.py
tests/test-bin-progs/__init__.py
tests/test_exclude.py
tests/tst_exclude1.py
tests/tst_dos_eol.py
tests/test_include.py
tests/tst_include1.py
tests/tst_end_comment.py
tests/test_section.py
tests/test_simple.py
[ ... over 116 regression tests elided ... ]

-> I think we should first do the tests I propose above, then you can
-> commit this patch with a test
-> without worrying of breaking something. Or if you have some better
-> strategy, let me know.

I would like to try to make a general fix by truly understanding the
sys.settrace functionality first, writing something from the ground up
that can correctly pick out lines that can be returned by sys.settrace,
and then going through all the regression tests that break to make sure
the new behavior is correct.  I predict incremental approaches like you
propose will lead to madness in this case -- at least they have for me,
hahAhaHAHAHhahahaa...

Ondrey I suspect a lot of people are confused...  If you can summarize
our private discussion, that might be good.  I'm about to fly somewhere,
so I won't get to it for a few days.

cheers,
--titus
-- 
C. Titus Brown, ctb at msu.edu



More information about the testing-in-python mailing list