def test_print_dependencies(capsys) -> None: """Expect all printed information in order.""" depinfo.print_dependencies("depinfo") captured = capsys.readouterr() lines = captured.out.split("\n") assert lines[1].startswith("System Information") assert lines[2].startswith("==================") assert lines[3].startswith("OS") assert lines[4].startswith("OS-release") assert lines[5].startswith("Python") assert lines[7].startswith("Package Versions") assert lines[8].startswith("================") assert any(line.startswith("depinfo") for line in lines[9:]) assert any(line.startswith("pip") for line in lines[9:]) assert any(line.startswith("setuptools") for line in lines[9:]) assert any(line.startswith("wheel") for line in lines[9:])
def test_print_dependencies(capsys) -> None: """Expect all printed information in order.""" with pytest.deprecated_call(): print_dependencies("depinfo") captured = capsys.readouterr() lines = captured.out.split("\n") assert lines[1].startswith("Platform Information") assert lines[2].startswith("--------------------") assert lines[3].startswith(platform.system()) assert lines[4].startswith(platform.python_implementation()) assert lines[6].startswith("Dependency Information") assert lines[7].startswith("----------------------") assert any(line.startswith("depinfo") for line in lines[8:]) assert any(line.startswith("pip") for line in lines[8:]) assert any(line.startswith("setuptools") for line in lines[8:]) assert any(line.startswith("wheel") for line in lines[8:])
def show_versions(): """Print dependency information.""" print_dependencies("cobra")
def show_versions(): """Print formatted dependency information to stdout.""" print_dependencies("memote")
def show_versions() -> None: """Print dependency information.""" print_dependencies("structurizr-python")
def show_versions(): """Print all dependencies with their versions.""" print_dependencies("sanger-sequencing")
def show_versions(): """Print dependency information.""" print_dependencies("metanetx-assets")
def show_versions() -> None: """Print dependency information.""" print_dependencies("sbmlutils")