use legacy error check in the common.TestSleep

This commit is contained in:
ninedraft 2020-09-03 23:07:04 +03:00
parent 34df4904f6
commit baf3495197
1 changed files with 1 additions and 2 deletions

View File

@ -2,7 +2,6 @@ package common_test
import (
"context"
"errors"
"testing"
"time"
@ -14,7 +13,7 @@ func TestSleep(test *testing.T) {
var t = func(name string, ctx context.Context, expected error) {
test.Run(name, func(test *testing.T) {
var err = common.Sleep(ctx, dt)
if !errors.Is(err, expected) {
if err != expected {
test.Errorf("expected %v, got %v", expected, err)
}
})