Back to index

python3.2  3.2.2
Public Member Functions
importlib.test.source.test_abc_loader.SkipWritingBytecodeTests Class Reference

List of all members.

Public Member Functions

def run_test
def test_no_bytecode_written
def test_bytecode_written

Detailed Description

Test that bytecode is properly handled based on
sys.dont_write_bytecode.

Definition at line 403 of file test_abc_loader.py.


Member Function Documentation

Definition at line 409 of file test_abc_loader.py.

00409 
00410     def run_test(self, dont_write_bytecode):
00411         name = 'mod'
00412         mock = PyPycLoaderMock({name: os.path.join('path', 'to', 'mod')})
00413         sys.dont_write_bytecode = dont_write_bytecode
00414         with util.uncache(name):
00415             mock.load_module(name)
00416         self.assertTrue((name in mock.module_bytecode) is not
00417                         dont_write_bytecode)

Here is the call graph for this function:

Definition at line 421 of file test_abc_loader.py.

00421 
00422     def test_bytecode_written(self):
00423         self.run_test(False)
00424 

Here is the call graph for this function:

Definition at line 418 of file test_abc_loader.py.

00418 
00419     def test_no_bytecode_written(self):
00420         self.run_test(True)

Here is the call graph for this function:


The documentation for this class was generated from the following file: