package
0.0.20
Repository: https://github.com/redhat-developer/ocdev.git
Documentation: pkg.go.dev

# Functions

CleanupEnv cleans up the mock config file and anything that SetupEnv generated Parameters: configFile: the mock config file handler t: testing pointer to log errors if any.
FakeClusterServiceClass creates a fake service class with the specified name for testing purposes.
FakeClusterServicePlan creates a fake plan with the specified external name and using planNumber to customize description, metadata and parameter values.
No description provided by the author
FakeImageStreams lists the imagestreams for the reactor.
FakeImageStreamTags lists the imagestreams for the reactor.
FakeKubeClientConfig returns mock kube client config.
FakeOdoConfig returns mock odo config It takes a confPath which is the path to the config.
FakeOnlyOneExistingProjects returns fake projectlist with single project for use by API mock functions for Unit tests testing delete of the only available project.
FakePlanServiceInstanceCreateParameterSchemasRaw creates 2 create parameter schemas for testing purposes.
FakeProjects returns fake projectlist for use by API mock functions for Unit tests.
FakeProjectStatus returns fake project status for use by mock watch on project.
FakeRemoveProject removes the delete requested project from the list of projects passed.
FakeServiceClassInstance creates and returns a simple service class instance for testing purpose serviceInstanceName is the name of the service class instance serviceClassName is the name of the service class planName is the name of the plan status is the status of the service instance.
RunPromptTest runs the specified PromptTest in the given testing context.
RunTest runs the given test using the specified procedure simulating the user interaction with the console.
SetUp sets up the odo and kube config files and returns respective conf file pointers and error.
SimulateFileModifications mock function to simulate requested file/folder operation Parameters: basePath: The parent directory for file/folder involved in desired file operation fileModification: Meta-data of file/folder Returns: path to file/folder involved in the operation error if any or nil.
SingleValuedRawExtension creates a simple, single valued (name=value), raw extension.
Stdio converts an expect.Console into a survey terminal.Stdio.
TempMkdir creates a temporary directory.
TempMkFile creates a temporary file.

# Constants

APPEND enum representing append operation on a file.
CREATE enum representing create operation for a file/folder.
DELETE enum representing delete operation for a file/folder.
Directory enum to represent directory.
RegularFile enum to represent regular file.
UPDATE enum representing update operation on a file.

# Structs

ConfigDetails struct holds configuration details(odo and/or kube config).
FileProperties to contain meta-data of a file like, file/folder name, file/folder parent dir, file type and desired file modification type.
PromptTest encapsulates a survey prompt test.

# Type aliases

FileType custom type to indicate type of file.
M is an alias for map[string]interface{}.
ModificationType custom type to indicate file modification type.