Fix tests
This commit is contained in:
parent
938f6f89b6
commit
b7dfa22f94
1 changed files with 3 additions and 2 deletions
|
@ -92,13 +92,14 @@ func TestAppsProcessorUpdateResources(t *testing.T) {
|
|||
err := processor.New("updateresources_1224", 1002, 1003, "testimage", 2, 256)
|
||||
assert.Nil(t, err)
|
||||
|
||||
err = processor.UpdateResources("updateresources_1224", "running", 1000, 256, 100, 200, detector.Flags{"test"})
|
||||
err = processor.UpdateResources("updateresources_1224", "running", true, 1000, 256, 100, 200, detector.Flags{"test"})
|
||||
assert.Nil(t, err)
|
||||
|
||||
app, err := processor.Get("updateresources_1224")
|
||||
assert.Nil(t, err)
|
||||
|
||||
assert.Equal(t, "running", app.State)
|
||||
assert.Equal(t, true, app.OOMKilled)
|
||||
assert.Equal(t, float64(1000), app.CPUUsage)
|
||||
assert.Equal(t, 256, app.MemoryUsage)
|
||||
assert.Equal(t, 100, app.DiskUsageBytes)
|
||||
|
@ -115,7 +116,7 @@ func TestAppsProcessorUpdateState(t *testing.T) {
|
|||
err := processor.New("update_1224", 1002, 1003, "testimage", 2, 256)
|
||||
assert.Nil(t, err)
|
||||
|
||||
err = processor.UpdateState("update_1224", "no-container")
|
||||
err = processor.UpdateState("update_1224", "no-container", false)
|
||||
assert.Nil(t, err)
|
||||
|
||||
app, err := processor.Get("update_1224")
|
||||
|
|
Loading…
Reference in a new issue