installtest

package
v0.52.0-rc.5 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Tester

type Tester struct {
	InstallTestClient *common.TestClient
	// contains filtered or unexported fields
}

Tester is a test helper for testing agent installations

func NewTester

func NewTester(tt *testing.T, host *components.RemoteHost, opts ...TesterOption) (*Tester, error)

NewTester creates a new Tester

func (*Tester) ExpectAPM

func (t *Tester) ExpectAPM() bool

ExpectAPM returns true if the agent is expected to install APM

func (*Tester) ExpectCWS

func (t *Tester) ExpectCWS() bool

ExpectCWS returns true if the agent is expected to install CWS

func (*Tester) ExpectPython2Installed

func (t *Tester) ExpectPython2Installed() bool

ExpectPython2Installed returns true if the agent is expected to install Python2

func (*Tester) InstallAgent

func (t *Tester) InstallAgent(tt *testing.T, args string, logfile string) error

InstallAgent installs the agent

func (*Tester) InstallAgentPackage

func (t *Tester) InstallAgentPackage(tt *testing.T, agentPackage *windowsAgent.Package, args string, logfile string) (string, error)

InstallAgentPackage installs the agent and returns any errors

func (*Tester) TestExpectations

func (t *Tester) TestExpectations(tt *testing.T) bool

TestExpectations tests the current agent installation meets the expectations provided to the Tester

func (*Tester) TestRuntimeExpectations

func (t *Tester) TestRuntimeExpectations(tt *testing.T)

TestRuntimeExpectations tests the runtime behavior of the agent

func (*Tester) TestUninstall

func (t *Tester) TestUninstall(tt *testing.T, logfile string) bool

TestUninstall uninstalls the agent and runs tests

type TesterOption

type TesterOption func(*Tester)

TesterOption is a function that can be used to configure a Tester

func WithAgentPackage

func WithAgentPackage(agentPackage *windowsAgent.Package) TesterOption

WithAgentPackage sets the agent package to be installed

func WithPreviousVersion

func WithPreviousVersion() TesterOption

WithPreviousVersion sets the Tester to expect a previous version of the agent to be installed and will not run all tests since expectations may have changed.

Jump to

Keyboard shortcuts

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