"""The driver cannot replace a device's configuration, and says so by not having the method. A ``load_replace_candidate`` that only raises looks like a replace to anyone who asks whether the driver has one: netOrk offered a config restore for these devices that could only fail (NetOrk/netork#2503). ``None`` is how a driver switches off a method it would otherwise inherit, the convention of napalm-device-types and netOrk's capability checks. """ from __future__ import annotations from napalm_linux import LinuxDriver def test_the_driver_has_no_config_replace(): assert LinuxDriver.load_replace_candidate is None assert not callable(getattr(LinuxDriver, "load_replace_candidate", None))