예제 #1
0
파일: test_exclude.py 프로젝트: ctb/figleaf
    def test_noexclude_misc_path(self):
        "Check that tests/tst_exclude1.py is covered, if no excl specified"
        figleaf.init(None, None)
        figleaf.start()

        execfile('tests/tst_exclude1.py')

        figleaf.stop()

        coverage = figleaf.get_data().gather_files()

        assert 'tests/tst_exclude1.py' in coverage.keys()
예제 #2
0
파일: test_include.py 프로젝트: ctb/figleaf
    def test_include_misc_path(self):
        "Check that tests/tst_include1.py is the only thing covered, if set"
        figleaf.init(None, 'tests')
        figleaf.start()

        execfile('tests/tst_include1.py')

        figleaf.stop()

        coverage = figleaf.get_data().gather_files()

        assert 'tests/tst_include1.py' in coverage.keys()
        assert len(coverage) == 1
예제 #3
0
파일: test_exclude.py 프로젝트: ctb/figleaf
    def test_exclude_misc_path(self):
        "Check that tests/tst_exclude1.py is not covered, if excl specified"


        testspath = os.path.abspath('tests/')
        print 'IGNORING', testspath
        
        figleaf.init(testspath, None)
        figleaf.start()

        execfile('tests/tst_exclude1.py')

        figleaf.stop()

        coverage = figleaf.get_data().gather_files()

        print coverage.keys()
        assert not 'tests/tst_exclude1.py' in coverage.keys()