mirror of
https://github.com/crowdsecurity/crowdsec.git
synced 2025-05-11 12:25:53 +02:00
Added support for .yaml.local files to override values in .yaml
This commit is contained in:
parent
635e633520
commit
98f2ac5e7c
17 changed files with 1088 additions and 42 deletions
|
@ -89,7 +89,7 @@ func TestSimulationLoading(t *testing.T) {
|
|||
},
|
||||
Crowdsec: &CrowdsecServiceCfg{},
|
||||
},
|
||||
err: fmt.Sprintf("while reading '%s': open %s: The system cannot find the file specified.", testXXFullPath, testXXFullPath),
|
||||
err: fmt.Sprintf("while reading %s: open %s: The system cannot find the file specified.", testXXFullPath, testXXFullPath),
|
||||
})
|
||||
} else {
|
||||
tests = append(tests, struct {
|
||||
|
@ -106,7 +106,7 @@ func TestSimulationLoading(t *testing.T) {
|
|||
},
|
||||
Crowdsec: &CrowdsecServiceCfg{},
|
||||
},
|
||||
err: fmt.Sprintf("while reading '%s': open %s: no such file or directory", testXXFullPath, testXXFullPath),
|
||||
err: fmt.Sprintf("while reading %s: open %s: no such file or directory", testXXFullPath, testXXFullPath),
|
||||
})
|
||||
}
|
||||
|
||||
|
@ -115,7 +115,8 @@ func TestSimulationLoading(t *testing.T) {
|
|||
if err == nil && test.err != "" {
|
||||
fmt.Printf("TEST '%s': NOK\n", test.name)
|
||||
t.Fatalf("%d/%d expected error, didn't get it", idx, len(tests))
|
||||
} else if test.err != "" {
|
||||
}
|
||||
if test.err != "" {
|
||||
if !strings.HasPrefix(fmt.Sprintf("%s", err), test.err) {
|
||||
fmt.Printf("TEST '%s': NOK\n", test.name)
|
||||
t.Fatalf("%d/%d expected '%s' got '%s'", idx, len(tests),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue