From c78fd09304c08a8d7c4852081206f5c49971ecb5 Mon Sep 17 00:00:00 2001 From: Brad Walker Date: Sat, 16 May 2020 13:02:21 -0600 Subject: [PATCH] Add invalid mtu to get_interfaces --- napalm_vyos/vyos.py | 1 + .../mocked_data/test_get_interfaces/normal/expected_result.json | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/napalm_vyos/vyos.py b/napalm_vyos/vyos.py index c2d87d8..670f4bb 100644 --- a/napalm_vyos/vyos.py +++ b/napalm_vyos/vyos.py @@ -349,6 +349,7 @@ class VyOSDriver(NetworkDriver): "is_enabled": bool(is_enabled), "description": py23_compat.text_type(description), "last_flapped": float(-1), + "mtu": -1, "speed": int(speed), "mac_address": py23_compat.text_type(hw_id) } diff --git a/test/unit/mocked_data/test_get_interfaces/normal/expected_result.json b/test/unit/mocked_data/test_get_interfaces/normal/expected_result.json index d4bf26f..2df2314 100644 --- a/test/unit/mocked_data/test_get_interfaces/normal/expected_result.json +++ b/test/unit/mocked_data/test_get_interfaces/normal/expected_result.json @@ -1 +1 @@ -{"lo": {"is_enabled": true, "description": "", "last_flapped": -1.0, "is_up": true, "mac_address": "00:00:00:00:00:00", "speed": 0}, "eth1": {"is_enabled": true, "description": "", "last_flapped": -1.0, "is_up": true, "mac_address": "...", "speed": 0}, "eth0": {"is_enabled": true, "description": "", "last_flapped": -1.0, "is_up": true, "mac_address": "...", "speed": 0}} +{"lo": {"is_enabled": true, "description": "", "last_flapped": -1.0, "is_up": true, "mac_address": "00:00:00:00:00:00", "mtu": -1, "speed": 0}, "eth1": {"is_enabled": true, "description": "", "last_flapped": -1.0, "is_up": true, "mac_address": "...", "mtu": -1, "speed": 0}, "eth0": {"is_enabled": true, "description": "", "last_flapped": -1.0, "is_up": true, "mac_address": "...", "mtu": -1, "speed": 0}}