(t *testing.T)
| 26 | } |
| 27 | |
| 28 | func TestSSHClient_WithExecutor(t *testing.T) { |
| 29 | me := &mockExecutor{} |
| 30 | client, err := NewSSHClient("192.0.2.1", "testuser", "", WithExecutor(me)) |
| 31 | require.NoError(t, err) |
| 32 | |
| 33 | err = client.Shell() |
| 34 | require.NoError(t, err) |
| 35 | require.Equal(t, 1, me.called) |
| 36 | require.Equal(t, "ssh", me.lastName) |
| 37 | require.Equal(t, []string{"testuser@192.0.2.1"}, me.lastArgs) |
| 38 | } |
| 39 | |
| 40 | func TestExecuteLXCShellWith_StandardContainer(t *testing.T) { |
| 41 | me := &mockExecutor{} |
nothing calls this directly
no test coverage detected