package
0.14.2
Repository: https://github.com/ubuntu/adsys.git
Documentation: pkg.go.dev

# Functions

BuildKrb5Mock takes the path to the location of the ad internal package and builds the libkrb5 mock for use with package or integration tests.
BuildWinbindMock takes the path to the location of the winbind internal package and builds the libwbclient mock for use with package or integration tests.
Chdir changes current directory to dir.
CompareTreesWithFiltering allows comparing a goldPath directory to p.
Copy copies files and directories to dest.
CreatePath creates a directory or a file with dummy content based on whether the given path contains a slash character at the end.
FormatBackendCalls takes a backend and returns a string containing a pretty representation of all calls to the exported functions of the interface.
GoldenPath returns the golden path for the provided test.
LoadWithUpdateFromGolden loads the element from a plaintext golden file.
LoadWithUpdateFromGoldenYAML load the generic element from a YAML serialized golden file.
MakeReadOnly makes dest read only and restore permission on cleanup.
MergeCoverages append all coverage files marked for merging to main Go Cover Profile.
NewDbusConn returns a system dbus connection which automatically close on test shutdown.
NormalizeGoldenName returns the name of the golden file with illegal Windows characters replaced or removed.
PreloadLibInSubprocess prepares a subprocess preloading a shared library for running tests.
PythonCoverageToGoFormat allow tracking python include file and convert them to the global go coverage profile commandOnStdin replace python3 binary to include with -c.
SetupSmb starts a local smbd process on specified part, serving sysvolDir.
SkipUnlessRoot skips the test if the current user is not root.
StartLocalSystemBus allows to start and set environment variable to a local bus, preventing polluting system ones.
TestFamilyPath returns the path of the dir for storing fixtures and other files related to the test.
TrackTestCoverage starts tracking coverage in a dedicated file based on current test name.
UpdateEnabled returns true if updating the golden files is requested.
WaitForWrites waits for test I/O to be picked up.
WantCoverage returns true if coverage was requested in test.
WithCoverageFormat overrides the default coverage format, impacting the filename of the coverage file.
WithGoldenPath overrides the default path for golden files used.
WriteFile writes a file by using the standard open & write procedure instead of using os.WriteFile.

# Constants

UpdateGoldenFilesEnv is the environment variable used to indicate go test that the golden files should be overwritten with the current test results.

# Structs

MockAssetsDumper is a mock implementation of the AssetsDumper function which uncompresses policy assets to a directory.
MockSystemdCaller is a mock implementation of the systemd caller interface.

# Type aliases

CoverageOption represents an optional function that can be used to override some of the coverage default values.
GoldenOption is a supported option reference to change the golden files comparison.