nose: nose.config
Classes
Highlighted methods are defined in this class.
nose configuration.
Instances of Config are used throughout nose to configure behavior, including plugin lists. Here are the default values for all config keys:
self.env = env = kw.pop('env', {}) self.args = () self.testMatch = re.compile(r'(?:^|[\b_\.%s-])[Tt]est' % os.sep) self.addPaths = not env.get('NOSE_NOPATH', False) self.configSection = 'nosetests' self.debug = env.get('NOSE_DEBUG') self.debugLog = env.get('NOSE_DEBUG_LOG') self.exclude = None self.getTestCaseNamesCompat = False self.includeExe = env.get('NOSE_INCLUDE_EXE', sys.platform in exe_allowed_platforms) self.ignoreFiles = (re.compile(r'^\.'), re.compile(r'^_'), re.compile(r'^setup\.py$') ) self.include = None self.loggingConfig = None self.logStream = sys.stderr self.options = NoOptions() self.parser = None self.plugins = NoPlugins() self.srcDirs = ('lib', 'src') self.runOnInit = True self.stopOnError = env.get('NOSE_STOP', False) self.stream = sys.stderr self.testNames = () self.verbosity = int(env.get('NOSE_VERBOSE', 1)) self.where = () self.workingDir = None
Methods
Configure the nose running environment. Execute configure before collecting tests with nose.TestCollector to enable output capture and other features.
Configure logging for nose, or optionally other packages. Any logger name may be set with the debug option, and that logger will be set to debug level and be assigned the same handler as the nose loggers, unless it already has a handler.
Configure the working directory or directories for the test run.
Reset all config values to defaults.
Get the command line option parser.
Return the generated help message
Methods
Handler for options from commandline and config files.
Methods
Methods
Options container that returns None for all options.
Methods
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
Functions
Return path to any existing user config files
Does the value look like an on/off flag?
Return path to any existing user config files, plus any setup.cfg in the current working directory.
Attributes
Default value: <logging.Logger instance>
Default value: ('win32', 'cli')
Default value: ['help', 'verbose']
Default value: ['~/.noserc', '~/nose.cfg']