mirror of
https://github.com/crowdsecurity/crowdsec.git
synced 2025-05-11 04:15:54 +02:00
Windows Support (#1159)
This commit is contained in:
parent
a49b023a28
commit
0449ec1868
100 changed files with 3401 additions and 437 deletions
|
@ -728,15 +728,15 @@ func TestAPICSendMetrics(t *testing.T) {
|
|||
}{
|
||||
{
|
||||
name: "basic",
|
||||
duration: time.Millisecond * 5,
|
||||
metricsInterval: time.Millisecond,
|
||||
duration: time.Millisecond * 30,
|
||||
metricsInterval: time.Millisecond * 5,
|
||||
expectedCalls: 5,
|
||||
setUp: func() {},
|
||||
},
|
||||
{
|
||||
name: "with some metrics",
|
||||
duration: time.Millisecond * 5,
|
||||
metricsInterval: time.Millisecond,
|
||||
duration: time.Millisecond * 30,
|
||||
metricsInterval: time.Millisecond * 5,
|
||||
expectedCalls: 5,
|
||||
setUp: func() {
|
||||
api.dbClient.Ent.Machine.Create().
|
||||
|
@ -862,7 +862,8 @@ func TestAPICPull(t *testing.T) {
|
|||
panic(err)
|
||||
}
|
||||
}()
|
||||
time.Sleep(time.Millisecond * 10)
|
||||
//Slightly long because the CI runner for windows are slow, and this can lead to random failure
|
||||
time.Sleep(time.Millisecond * 500)
|
||||
logrus.SetOutput(os.Stderr)
|
||||
assert.Contains(t, buf.String(), testCase.logContains)
|
||||
assertTotalDecisionCount(t, api.dbClient, testCase.expectedDecisionCount)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue