diff --git a/go/src/hello_test.go b/go/src/hello_test.go index 3a7fc4382..06db72316 100644 --- a/go/src/hello_test.go +++ b/go/src/hello_test.go @@ -43,3 +43,16 @@ func TimeIsNotReal(t *testing.T) { time.Sleep(600 * time.Millisecond) } } + +// passes if the current second is even +func TimeIsNotComplex(t *testing.T) { + + currentTime := time.Now() + sec := currentTime.Second() + + if sec%2 != 0 { + t.Errorf("Second '%d' is not even", sec) + // Sleep so retry cases can pass (sometimes) + time.Sleep(600 * time.Millisecond) + } +}