Documentation ¶
Index ¶
Constants ¶
const ( GremlinsSilentKey = "silent" UnleashDryRunKey = "unleash.dry-run" UnleashOutputStatusesKey = "unleash.output-statuses" UnleashOutputKey = "unleash.output" UnleashTagsKey = "unleash.tags" UnleashCoverPkgKey = "unleash.coverpkg" UnleashWorkersKey = "unleash.workers" UnleashTestCPUKey = "unleash.test-cpu" UnleashTimeoutCoefficientKey = "unleash.timeout-coefficient" UnleashIntegrationMode = "unleash.integration" UnleashExcludeFiles = "unleash.exclude-files" UnleashDiffRef = "unleash.diff" UnleashGithubToken = "unleash.github-token" UnleashGithubRepo = "unleash.github-repo" UnleashThresholdEfficacyKey = "unleash.threshold.efficacy" UnleashThresholdMCoverageKey = "unleash.threshold.mutant-coverage" )
This is the list of the keys available in config files and as flags.
Variables ¶
This section is empty.
Functions ¶
func Init ¶
Init initializes the viper configuration for Gremlins.
It sets the configuration file name as .gremlins.yaml, adds the passed paths as ConfigPaths AutomaticEnv configuration having GREMLINS as prefix. The environment variables take precedence over the configuration file and must be set in the format:
GREMLINS_<COMMAND NAME>_<FLAG NAME>
func IsDefaultEnabled ¶
IsDefaultEnabled returns the default enabled/disabled state of the mutation. It gets the state from the table above that must be kept up to date when adding new mutant types.
func MutantTypeEnabledKey ¶
MutantTypeEnabledKey returns the configuration key for a mutant. The generated key will have the format 'mutants.mutant-name.enabled", which corresponds to the Yaml:
mutants: mutant-name: enabled: [bool]
Types ¶
This section is empty.