servicetest

package
v0.57.0-rc.1 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package servicetest provides tests for the services installed by the Windows Agent

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertEqualServiceConfigValues added in v0.54.0

func AssertEqualServiceConfigValues(t *testing.T, expected windowsCommon.ServiceConfigMap, actual windowsCommon.ServiceConfigMap) bool

AssertEqualServiceConfigValues asserts that the service config values from the expected map match the actual map

func ExpectedInstalledServices added in v0.54.0

func ExpectedInstalledServices() []string

ExpectedInstalledServices returns the list of services expected to be installed

func ExpectedRunningServices added in v0.56.0

func ExpectedRunningServices() []string

ExpectedRunningServices returns the list of services expected to be running after installation

Types

type Option

type Option = func(*Tester) error

Option is a functional option for Tester

func WithExpectedAgentUser

func WithExpectedAgentUser(domain string, username string) Option

WithExpectedAgentUser sets the expected user for the Agent

func WithExpectedConfigRoot added in v0.54.0

func WithExpectedConfigRoot(path string) Option

WithExpectedConfigRoot sets the expected config root for the agent

func WithExpectedInstallPath added in v0.54.0

func WithExpectedInstallPath(path string) Option

WithExpectedInstallPath sets the expected install path for the agent

type Tester

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

Tester provides tests for the services installed by the Windows Agent

func NewTester

func NewTester(host *components.RemoteHost, opts ...Option) (*Tester, error)

NewTester creates a new Tester

func (*Tester) ExpectedServiceConfig added in v0.54.0

func (t *Tester) ExpectedServiceConfig() (windowsCommon.ServiceConfigMap, error)

ExpectedServiceConfig returns the expected service config for the installed services

Jump to

Keyboard shortcuts

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