Skip to content

Commit

Permalink
chore: update unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sweatybridge committed Jan 31, 2025
1 parent 9e2a740 commit a5d71d8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion internal/db/diff/diff_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,8 @@ func TestDiffDatabase(t *testing.T) {
// Check error
assert.Empty(t, diff)
assert.ErrorContains(t, err, `ERROR: schema "public" already exists (SQLSTATE 42P06)
At statement 0: create schema public`)
At statement 0:
create schema public`)
assert.Empty(t, apitest.ListUnmatchedRequests())
})

Expand Down
2 changes: 1 addition & 1 deletion internal/db/push/push_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ func TestMigrationPush(t *testing.T) {
err := Run(context.Background(), false, false, false, false, dbConfig, fsys, conn.Intercept)
// Check error
assert.ErrorContains(t, err, `ERROR: null value in column "version" of relation "schema_migrations" (SQLSTATE 23502)`)
assert.ErrorContains(t, err, "At statement 0: "+migration.INSERT_MIGRATION_VERSION)
assert.ErrorContains(t, err, "At statement 0:\n"+migration.INSERT_MIGRATION_VERSION)
})
}

Expand Down

0 comments on commit a5d71d8

Please sign in to comment.