Esempio n. 1
0
 def trace_coverage_support(self, sample_filename):
     try:
         import trace
         trace.find_executable_linenos(sample_filename)
         return True
     except NotImplementedError:
         return False
Esempio n. 2
0
 def test_deprecated_find_executable_linenos(self):
     with open(TESTFN, 'w') as fd:
         self.addCleanup(unlink, TESTFN)
     with self.assertWarns(DeprecationWarning):
         trace.find_executable_linenos(fd.name)
Esempio n. 3
0
 def test_deprecated_find_executable_linenos(self):
     with open(TESTFN, 'w') as fd:
         self.addCleanup(unlink, TESTFN)
     with self.assertWarns(DeprecationWarning):
         trace.find_executable_linenos(fd.name)
Esempio n. 4
0
 def test_deprecated_find_executable_linenos(self):
     with self.assertWarns(DeprecationWarning):
         with tempfile.NamedTemporaryFile() as fd:
             trace.find_executable_linenos(fd.name)