diff options
Diffstat (limited to 'internal/config.go')
| -rw-r--r-- | internal/config.go | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/internal/config.go b/internal/config.go index 85782cf..cb55ec8 100644 --- a/internal/config.go +++ b/internal/config.go @@ -53,3 +53,14 @@ func newConfig(configFile string) (config, error) { return config, nil } + +func (c config) sanityCheck() error { + for name, check := range c.Checks { + for _, depName := range check.DependsOn { + if _, ok := c.Checks[depName]; !ok { + return fmt.Errorf("check '%s' depends on non existant check '%s'", depName, name) + } + } + } + return nil +} |
