testutils

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2025 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AreDirsEqual added in v1.1.0

func AreDirsEqual(source string, dest string) (bool, error)

AreDirsEqual recursively compares two directories for equality NOTE: filepath.Wale guarantees lexical order traversal (elements already ordered) thus allowing us to use a slice as opposed to a map.

func CreateProcessToTerminate added in v1.2.5

func CreateProcessToTerminate() (int, error)

CreateProcessToTerminate creates a process that to be killed for testing

func MakeAferoTestFs

func MakeAferoTestFs(filesMap map[string][]byte) (afero.Fs, error)

MakeAferoTestFs is a convenience function that lets you construct many directories and files in an afero in-memory filesystem by passing a single path->contents map

func MakeTempTestDir added in v1.1.0

func MakeTempTestDir(filesMap map[string][]byte) (string, error)

MakeTempTestDir is used to populate a temporary directory with the file/directory contents specified in filesMap. It is useful for setting up temporary test environments

**Parameters:**

filesMap: A pointer to a TTPExecutionConfig that represents the execution configuration for the TTP.

**Returns:**

* the created temporary directory path * an error if any part of the process failed

Types

This section is empty.

Jump to

Keyboard shortcuts

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