API reference

parametrize_from_file

Parametrize test functions with values read from config files.

parametrize_from_file.parametrize([path, ...])

Parametrize a test function with values read from a config file.

parametrize_from_file.fixture([path, key, ...])

Parametrize a fixture function with values read from a config file.

parametrize_from_file.Namespace(*args, **kwargs)

Evaluate and/or execute snippets of python code, with powerful control over the names available to those snippets.

parametrize_from_file.cast(**funcs)

Return a schema function that will apply functions to the given test parameters.

parametrize_from_file.defaults(**defaults)

Return a schema function that will add the given default values to test cases.

parametrize_from_file.rename([names])

Return a schema function that will rename the specified parameters.

parametrize_from_file.error(exc_spec, *[, ...])

Create a context manager that will check that the specified exception is raised.

parametrize_from_file.error_or(*expected[, ...])

Return a schema function that will expect to be given either an error or the specified set of expected values.

parametrize_from_file.star(module)

Return a dictionary containing all public attributes exposed by the given module.

parametrize_from_file.add_loader(suffix, loader)

Read test parameters from a custom file type.

parametrize_from_file.drop_loader(suffix)

Prevent parameters from being read from files with the given suffix.

parametrize_from_file.load_parameters(path, ...)

Load test parameters from a file.

parametrize_from_file.ConfigError([brief])

Raised when unable to find and/or load test parameters.