def test_put(self, mock_scp_client_type): auto_connect_ssh = AutoConnectSSH('user1', 'host1') auto_connect_ssh._client = mock.Mock() auto_connect_ssh.put('a', 'z') with mock_scp_client_type() as mock_scp_client: self.assertEqual(mock_scp_client.put.call_count, 1)
def test_put(self, mock_scp_client_type): auto_connect_ssh = AutoConnectSSH('user1', 'host1') auto_connect_ssh._client = mock.Mock() auto_connect_ssh.put('a', 'z') with mock_scp_client_type() as mock_scp_client: mock_scp_client.put.assert_called_once()