meta_package_manager.tests.case module — Meta Package Manager 2.4.0 documentation

# meta_package_manager.tests.case module

`meta_package_manager.tests.case.` `skip_destructive`()

  Decorator to skip a test unless destructive mode is allowed.

  Destructive mode is activated by the presence of a `DESTRUCTIVE_TESTS` environment variable set to `True`.

`meta_package_manager.tests.case.` `unless_linux`()

  Decorator to skip a test unless it is run on a Linux system.

`meta_package_manager.tests.case.` `unless_macos`()

  Decorator to skip a test unless it is run on a macOS system.

`meta_package_manager.tests.case.` `unless_windows`()

  Decorator to skip a test unless it is run on a Windows system.

class `meta_package_manager.tests.case.` `CLITestCase`(methodName='runTest')

  Bases: `unittest.case.TestCase`

  Utilities and helpers to easely write unit-tests.

  Create an instance of the class that will use the named test method when executed. Raises a ValueError if the instance does not have a method with the specified name.

  `setUp`()
  `print_cli_output`(cmd, output)

    Simulate CLI output.

    Used to print debug traces in test suites.

  `run_cmd`(*args)

    Run a system command, print output and return results.

  `invoke`(*args)

    Executes Click’s CLI, print output and return results.