Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

release 🚚 #62

Open
wants to merge 1 commit into
base: release
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ __pycache__/
.pytest_cache/
.ruff_cache/
*.egg-info/
.coverage/
.coverage/
.coverage
2 changes: 1 addition & 1 deletion device-discovery/device_discovery/discovery.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def napalm_driver_list() -> list[str]:
discovered driver names from the installed packages.

"""
napalm_packages = ["ios", "eos", "junos", "nxos"]
napalm_packages = ["eos", "ios", "iosxr_netconf", "junos", "nxos", "nxos_ssh"]
prefix = "napalm_"
for dist in packages_distributions():
if dist.startswith(prefix):
Expand Down
13 changes: 11 additions & 2 deletions device-discovery/tests/test_discovery.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,16 @@ class MockDriver(NetworkDriver):

mock_packages_distributions.return_value = mock_distributions

expected_drivers = ["ios", "eos", "junos", "nxos", "srl", "fake_driver"]
expected_drivers = [
"eos",
"ios",
"iosxr_netconf",
"junos",
"nxos",
"nxos_ssh",
"srl",
"fake_driver",
]
drivers = napalm_driver_list()
assert drivers == expected_drivers, f"Expected {expected_drivers}, got {drivers}"

Expand All @@ -209,7 +218,7 @@ def test_napalm_driver_list_error(mock_packages_distributions, mock_import_modul

mock_import_module.side_effect = Exception("Import failed")
mock_packages_distributions.return_value = mock_distributions
expected_drivers = ["ios", "eos", "junos", "nxos"]
expected_drivers = ["eos", "ios", "iosxr_netconf", "junos", "nxos", "nxos_ssh"]

with patch("device_discovery.discovery.logger") as mock_logger:
drivers = napalm_driver_list()
Expand Down
Loading