tests: eval may be processed quickly

This commit is contained in:
Mahmood Ali 2020-05-26 18:18:59 -04:00
parent 14e540cf46
commit 5d80d2a511
1 changed files with 6 additions and 1 deletions

View File

@ -2509,7 +2509,12 @@ func TestClientEndpoint_CreateNodeEvals(t *testing.T) {
require.Equal(t, structs.EvalTriggerNodeUpdate, eval.TriggeredBy)
require.Equal(t, alloc.NodeID, eval.NodeID)
require.Equal(t, uint64(1), eval.NodeModifyIndex)
switch eval.Status {
case structs.EvalStatusPending, structs.EvalStatusComplete:
// success
default:
require.Equal(t, structs.EvalStatusPending, eval.Status)
}
require.Equal(t, expPriority, eval.Priority)
require.Equal(t, expJobID, eval.JobID)
require.NotZero(t, eval.CreateTime)