Back to index

python3.2  3.2.2
Public Member Functions | Static Public Attributes
importlib.test.source.test_abc_loader.PyPycLoaderTests Class Reference
Inheritance diagram for importlib.test.source.test_abc_loader.PyPycLoaderTests:
Inheritance graph
[legend]
Collaboration diagram for importlib.test.source.test_abc_loader.PyPycLoaderTests:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def verify_bytecode
def test_module
def test_package
def test_lacking_parent
def test_module_reuse
def test_state_after_failure
def test_unloadable
def eq_attrs

Static Public Attributes

 mocker = PyPycLoaderMock

Detailed Description

Tests for importlib.abc.PyPycLoader.

Definition at line 331 of file test_abc_loader.py.


Member Function Documentation

def importlib.test.source.test_abc_loader.PyLoaderTests.eq_attrs (   self,
  ob,
  kwargs 
) [inherited]

Definition at line 210 of file test_abc_loader.py.

00210 
00211     def eq_attrs(self, ob, **kwargs):
00212         for attr, val in kwargs.items():
00213             found = getattr(ob, attr)
00214             self.assertEqual(found, val,
00215                     "{} attribute: {} != {}".format(attr, found, val))

Here is the call graph for this function:

Here is the caller graph for this function:

Reimplemented from importlib.test.source.test_abc_loader.PyLoaderTests.

Definition at line 356 of file test_abc_loader.py.

00356 
00357     def test_lacking_parent(self):
00358         mock, name = super().test_lacking_parent()
00359         self.verify_bytecode(mock, name)

Here is the call graph for this function:

Reimplemented from importlib.test.source.test_abc_loader.PyLoaderTests.

Definition at line 348 of file test_abc_loader.py.

00348 
00349     def test_module(self):
00350         mock, name = super().test_module()
00351         self.verify_bytecode(mock, name)

Here is the call graph for this function:

Reimplemented from importlib.test.source.test_abc_loader.PyLoaderTests.

Definition at line 360 of file test_abc_loader.py.

00360 
00361     def test_module_reuse(self):
00362         mock, name = super().test_module_reuse()
00363         self.verify_bytecode(mock, name)

Here is the call graph for this function:

Reimplemented from importlib.test.source.test_abc_loader.PyLoaderTests.

Definition at line 352 of file test_abc_loader.py.

00352 
00353     def test_package(self):
00354         mock, name = super().test_package()
00355         self.verify_bytecode(mock, name)

Here is the call graph for this function:

Reimplemented from importlib.test.source.test_abc_loader.PyLoaderTests.

Definition at line 364 of file test_abc_loader.py.

00364 
00365     def test_state_after_failure(self):
00366         super().test_state_after_failure()

Reimplemented from importlib.test.source.test_abc_loader.PyLoaderTests.

Definition at line 367 of file test_abc_loader.py.

00367 
00368     def test_unloadable(self):
00369         super().test_unloadable()
00370 

Definition at line 338 of file test_abc_loader.py.

00338 
00339     def verify_bytecode(self, mock, name):
00340         assert name in mock.module_paths
00341         self.assertIn(name, mock.module_bytecode)
00342         magic = mock.module_bytecode[name][:4]
00343         self.assertEqual(magic, imp.get_magic())
00344         mtime = importlib._r_long(mock.module_bytecode[name][4:8])
00345         self.assertEqual(mtime, 1)
00346         bc = mock.module_bytecode[name][8:]
00347         self.assertEqual(bc, mock.compile_bc(name))

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

Reimplemented from importlib.test.source.test_abc_loader.PyLoaderTests.

Definition at line 335 of file test_abc_loader.py.


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