Documentation ¶
Index ¶
- Variables
- func CreateDirIn(dir string, dirName string) (string, error)
- func CreateFileIn(dir string, fileName string, data []byte) (string, error)
- func Download(url, targetDir, fileName string, silent bool) (string, error)
- func DownloadAndUnzip(downloadLink string, tempDir string) (string, error)
- func FindAllNestedDirs(dir string) []string
- func FindConceptFilesIn(dir string) []string
- func FindSpecFilesIn(dir string) []string
- func GetConceptFiles(path string) []string
- func GetPathToFile(path string) string
- func GetSpecFiles(path string) []string
- func IsConcept(path string) bool
- func IsDir(path string) bool
- func IsProcessRunning(pid int) bool
- func IsSpec(path string) bool
- func IsValidConceptExtension(path string) bool
- func IsValidSpecExtension(path string) bool
- func IsWindows() bool
- func NumberOfCores() int
- func Remove(dir string)
- func RemoveTempDir()
- func SaveFile(fileName string, content string, backup bool)
- func SetWorkingDir(workingDir string)
Constants ¶
This section is empty.
Variables ¶
var AcceptedExtensions = make(map[string]bool)
AcceptedExtensions has all the file extensions that are supported by Gauge for its specs
Functions ¶
func CreateDirIn ¶
CreateDirIn creates a dir in given path
func CreateFileIn ¶
CreateFileIn creates a file `fileName` in given dir with its content as data
func Download ¶ added in v0.3.2
Download fires a HTTP GET request to download a resource to target directory
func DownloadAndUnzip ¶ added in v0.3.0
DownloadAndUnzip downloads the zip file from given download link and unzips it. Returns the unzipped file path.
func FindAllNestedDirs ¶ added in v0.1.3
FindAllNestedDirs returns list of all nested directories in given path
func FindConceptFilesIn ¶
FindConceptFilesIn Finds the concept files in specified directory
func FindSpecFilesIn ¶
FindSpecFilesIn Finds spec files in the given directory
func GetConceptFiles ¶ added in v0.4.0
GetConceptFiles returns the list of concept files present at the given path. If the given path is a file, it searches for concepts in the PROJECTROOT/base_dir_of_path
func GetPathToFile ¶ added in v0.1.7
GetPathToFile returns the path to a given file from the Project root
func GetSpecFiles ¶ added in v0.1.7
GetSpecFiles returns the list of spec files present at the given path. If the path itself represents a spec file, it returns the same.
func IsProcessRunning ¶ added in v0.3.2
IsProcessRunning checks if the process with the given process id is still running
func IsValidConceptExtension ¶
IsValidConceptExtension Checks if the path has a concept file extension
func IsValidSpecExtension ¶
IsValidSpecExtension Checks if the path has a spec file extension
func IsWindows ¶ added in v0.1.7
func IsWindows() bool
IsWindows returns if Gauge is running on Windows
func NumberOfCores ¶ added in v0.1.7
func NumberOfCores() int
NumberOfCores returns the number of CPU cores on the system
func Remove ¶ added in v0.3.0
func Remove(dir string)
Remove removes all the files and directories recursively for the given path
func SetWorkingDir ¶ added in v0.4.0
func SetWorkingDir(workingDir string)
SetWorkingDir sets the current working directory to specified location
Types ¶
This section is empty.