mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-30 06:03:45 +01:00
fix tc
This commit is contained in:
parent
436f0efab8
commit
7fdb77f6d2
@ -26,13 +26,14 @@ func TestTimeMarker(t *testing.T) {
|
||||
m := &TimeMarker{
|
||||
interval: 1 * time.Second,
|
||||
}
|
||||
r1 := m.Mark()
|
||||
r1 := m.Check()
|
||||
assert.True(r1)
|
||||
r2 := m.Mark()
|
||||
m.Mark()
|
||||
r2 := m.Check()
|
||||
assert.False(r2)
|
||||
t.Log("Sleep for 2 seconds...")
|
||||
time.Sleep(2 * time.Second)
|
||||
r3 := m.Mark()
|
||||
r3 := m.Check()
|
||||
assert.True(r3)
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user