sshutils

package
v0.1.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 29, 2025 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockSshManager

type MockSshManager struct {
	mock.Mock
}

MockSshManager is an autogenerated mock type for the SshManager type

func NewMockSshManager

func NewMockSshManager(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockSshManager

NewMockSshManager creates a new instance of MockSshManager. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.

func (*MockSshManager) DisablePasswordSSHLogin

func (_m *MockSshManager) DisablePasswordSSHLogin() error

DisablePasswordSSHLogin provides a mock function with no fields

func (*MockSshManager) EXPECT

func (*MockSshManager) ExchangeKeys

func (_m *MockSshManager) ExchangeKeys(sshKeyPath string) error

ExchangeKeys provides a mock function with given fields: sshKeyPath

func (*MockSshManager) ExecuteScript

func (_m *MockSshManager) ExecuteScript(scriptPath string, scriptContent string, postRemove bool, runWithSudo bool) error

ExecuteScript provides a mock function with given fields: scriptPath, scriptContent, postRemove, runWithSudo

func (*MockSshManager) IsInit

func (_m *MockSshManager) IsInit() bool

IsInit provides a mock function with no fields

func (*MockSshManager) RebootCloudInit

func (_m *MockSshManager) RebootCloudInit() error

RebootCloudInit provides a mock function with no fields

func (*MockSshManager) WriteFileOnRemoteMachine

func (_m *MockSshManager) WriteFileOnRemoteMachine(path string, fileContent string, fileMode fs.FileMode) error

WriteFileOnRemoteMachine provides a mock function with given fields: path, fileContent, fileMode

type MockSshManager_DisablePasswordSSHLogin_Call

type MockSshManager_DisablePasswordSSHLogin_Call struct {
	*mock.Call
}

MockSshManager_DisablePasswordSSHLogin_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DisablePasswordSSHLogin'

func (*MockSshManager_DisablePasswordSSHLogin_Call) Return

func (*MockSshManager_DisablePasswordSSHLogin_Call) Run

func (*MockSshManager_DisablePasswordSSHLogin_Call) RunAndReturn

type MockSshManager_ExchangeKeys_Call

type MockSshManager_ExchangeKeys_Call struct {
	*mock.Call
}

MockSshManager_ExchangeKeys_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ExchangeKeys'

func (*MockSshManager_ExchangeKeys_Call) Return

func (*MockSshManager_ExchangeKeys_Call) Run

func (*MockSshManager_ExchangeKeys_Call) RunAndReturn

type MockSshManager_ExecuteScript_Call

type MockSshManager_ExecuteScript_Call struct {
	*mock.Call
}

MockSshManager_ExecuteScript_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ExecuteScript'

func (*MockSshManager_ExecuteScript_Call) Return

func (*MockSshManager_ExecuteScript_Call) Run

func (_c *MockSshManager_ExecuteScript_Call) Run(run func(scriptPath string, scriptContent string, postRemove bool, runWithSudo bool)) *MockSshManager_ExecuteScript_Call

func (*MockSshManager_ExecuteScript_Call) RunAndReturn

type MockSshManager_Expecter

type MockSshManager_Expecter struct {
	// contains filtered or unexported fields
}

func (*MockSshManager_Expecter) DisablePasswordSSHLogin

DisablePasswordSSHLogin is a helper method to define mock.On call

func (*MockSshManager_Expecter) ExchangeKeys

func (_e *MockSshManager_Expecter) ExchangeKeys(sshKeyPath interface{}) *MockSshManager_ExchangeKeys_Call

ExchangeKeys is a helper method to define mock.On call

  • sshKeyPath string

func (*MockSshManager_Expecter) ExecuteScript

func (_e *MockSshManager_Expecter) ExecuteScript(scriptPath interface{}, scriptContent interface{}, postRemove interface{}, runWithSudo interface{}) *MockSshManager_ExecuteScript_Call

ExecuteScript is a helper method to define mock.On call

  • scriptPath string
  • scriptContent string
  • postRemove bool
  • runWithSudo bool

func (*MockSshManager_Expecter) IsInit

IsInit is a helper method to define mock.On call

func (*MockSshManager_Expecter) RebootCloudInit

RebootCloudInit is a helper method to define mock.On call

func (*MockSshManager_Expecter) WriteFileOnRemoteMachine

func (_e *MockSshManager_Expecter) WriteFileOnRemoteMachine(path interface{}, fileContent interface{}, fileMode interface{}) *MockSshManager_WriteFileOnRemoteMachine_Call

WriteFileOnRemoteMachine is a helper method to define mock.On call

  • path string
  • fileContent string
  • fileMode fs.FileMode

type MockSshManager_IsInit_Call

type MockSshManager_IsInit_Call struct {
	*mock.Call
}

MockSshManager_IsInit_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IsInit'

func (*MockSshManager_IsInit_Call) Return

func (*MockSshManager_IsInit_Call) Run

func (*MockSshManager_IsInit_Call) RunAndReturn

func (_c *MockSshManager_IsInit_Call) RunAndReturn(run func() bool) *MockSshManager_IsInit_Call

type MockSshManager_RebootCloudInit_Call

type MockSshManager_RebootCloudInit_Call struct {
	*mock.Call
}

MockSshManager_RebootCloudInit_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RebootCloudInit'

func (*MockSshManager_RebootCloudInit_Call) Return

func (*MockSshManager_RebootCloudInit_Call) Run

func (*MockSshManager_RebootCloudInit_Call) RunAndReturn

type MockSshManager_WriteFileOnRemoteMachine_Call

type MockSshManager_WriteFileOnRemoteMachine_Call struct {
	*mock.Call
}

MockSshManager_WriteFileOnRemoteMachine_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'WriteFileOnRemoteMachine'

func (*MockSshManager_WriteFileOnRemoteMachine_Call) Return

func (*MockSshManager_WriteFileOnRemoteMachine_Call) Run

func (*MockSshManager_WriteFileOnRemoteMachine_Call) RunAndReturn

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL