MCPcopy Create free account
hub / github.com/Driver-C/tryssh / TestTryLogin_EmptyUser

Function TestTryLogin_EmptyUser

pkg/control/ssh_integration_test.go:93–102  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

91}
92
93func TestTryLogin_EmptyUser(t *testing.T) {
94 cfg, _ := setupSSHTestConfig(t)
95
96 ctrl := NewSSHController("192.168.1.1", cfg)
97 ctrl.TryLogin("", 1, 1*time.Nanosecond)
98
99 // Empty user should find any cache matching IP
100 assert.Equal(t, "192.168.1.1", ctrl.targetIP)
101 assert.True(t, ctrl.cacheIsFound)
102}
103
104func TestTryLogin_NoCombinations(t *testing.T) {
105 cfg, _ := setupSSHTestConfig(t)

Callers

nothing calls this directly

Calls 3

TryLoginMethod · 0.95
setupSSHTestConfigFunction · 0.85
NewSSHControllerFunction · 0.85

Tested by

no test coverage detected