feat: TYPE_LABEL = "Linux" overrides OSDriver.TYPE_LABEL = "OS"

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Christian Manivong
2026-06-24 11:37:29 +02:00
co-authored by Claude Sonnet 4.6
parent e065515de0
commit 450aa193ba
2 changed files with 16 additions and 0 deletions
+1
View File
@@ -93,6 +93,7 @@ class LinuxDriver(OSDriver):
package manager unless overridden by ``optional_args["pkg_manager"]``.
"""
TYPE_LABEL = "Linux"
VENDOR = "Linux"
NETMIKO_DEVICE_TYPE = "linux"
+15
View File
@@ -341,6 +341,21 @@ def test_apply_updates_unsupported_pm_raises(driver):
driver.apply_updates(["curl"])
# ---------------------------------------------------------------------------
# TYPE_LABEL
# ---------------------------------------------------------------------------
def test_type_label_is_linux():
assert LinuxDriver.TYPE_LABEL == "Linux"
def test_type_label_overrides_os_driver():
from napalm_device_types import OSDriver
assert OSDriver.TYPE_LABEL == "OS"
assert LinuxDriver.TYPE_LABEL != OSDriver.TYPE_LABEL
# ---------------------------------------------------------------------------
# _collect_platform_info
# ---------------------------------------------------------------------------