Пример #1
0
def test_cli_multi_command():
    """
    Test that CLI works with 2 arg
    """
    with patch(
        "salt.utils.napalm.get_device",
        MagicMock(return_value=napalm_test_support.MockNapalmDevice()),
    ):
        ret = napalm_network.cli("show run", "show run")
        assert ret["out"] == napalm_test_support.TEST_COMMAND_RESPONSE.copy()
Пример #2
0
 def test_cli_multi_command(self):
     '''
     Test that CLI works with 2 arg
     '''
     ret = napalm_network.cli("show run", "show run")
     assert ret['out'] == TEST_COMMAND_RESPONSE
Пример #3
0
 def test_cli_multi_command(self):
     """
     Test that CLI works with 2 arg
     """
     ret = napalm_network.cli("show run", "show run")
     assert ret["out"] == napalm_test_support.TEST_COMMAND_RESPONSE.copy()
Пример #4
0
 def test_cli_single_command(self):
     '''
     Test that CLI works with 1 arg
     '''
     ret = napalm_network.cli("show run")
     assert ret['out'] == napalm_test_support.TEST_COMMAND_RESPONSE