Use testify/require instead of testify/assert for tests.

This commit is contained in:
go-jet 2020-05-09 11:00:22 +02:00
parent ebcbadef24
commit 5d742837f1
32 changed files with 581 additions and 589 deletions

View file

@ -4,7 +4,7 @@ import (
"github.com/go-jet/jet/internal/testutils"
. "github.com/go-jet/jet/mysql"
. "github.com/go-jet/jet/tests/.gentestdata/mysql/dvds/table"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"testing"
)
@ -16,7 +16,7 @@ LOCK TABLES dvds.customer READ;
`)
_, err := query.Exec(db)
assert.NoError(t, err)
require.NoError(t, err)
}
func TestLockWrite(t *testing.T) {
@ -27,7 +27,7 @@ LOCK TABLES dvds.customer WRITE;
`)
_, err := query.Exec(db)
assert.NoError(t, err)
require.NoError(t, err)
}
func TestUnlockTables(t *testing.T) {
@ -38,5 +38,5 @@ UNLOCK TABLES;
`)
_, err := query.Exec(db)
assert.NoError(t, err)
require.NoError(t, err)
}