Known subclasses: twisted.python.test.test_deprecate.ImportedModuleAttributeTests, twisted.test.test_application.PluggableReactorTests, twisted.test.test_modules.TwistedModulesTestCase

A mixin for twisted.trial.unittest.SynchronousTestCase providing useful methods for manipulating Python's module system.

Method replaceSysPath Replace sys.path, for the duration of the test, with the given value.
Method replaceSysModules Replace sys.modules, for the duration of the test, with the given value.
Method pathEntryWithOnePackage Generate a FilePath with one package, named pkgname, on it, and return the FilePath of the path entry.
def replaceSysPath(self, sysPath):

Replace sys.path, for the duration of the test, with the given value.

def replaceSysModules(self, sysModules):

Replace sys.modules, for the duration of the test, with the given value.

def pathEntryWithOnePackage(self, pkgname='test_package'):

Generate a FilePath with one package, named pkgname, on it, and return the FilePath of the path entry.

API Documentation for twisted, generated by pydoctor at 2020-03-25 17:34:30.