mirror of
https://github.com/SecurityBrewery/catalyst.git
synced 2026-01-24 06:53:27 +01:00
refactor: remove pocketbase (#1138)
This commit is contained in:
21
app/database/db_test.go
Normal file
21
app/database/db_test.go
Normal file
@@ -0,0 +1,21 @@
|
||||
package database_test
|
||||
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/stretchr/testify/assert"
|
||||
|
||||
"github.com/SecurityBrewery/catalyst/app/database"
|
||||
"github.com/SecurityBrewery/catalyst/app/database/sqlc"
|
||||
)
|
||||
|
||||
func TestDBForeignKeyConstraints(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
queries := database.TestDB(t, t.TempDir())
|
||||
|
||||
assert.Error(t, queries.AssignGroupToUser(t.Context(), sqlc.AssignGroupToUserParams{
|
||||
UserID: "does_not_exist",
|
||||
GroupID: "also_missing",
|
||||
}))
|
||||
}
|
||||
Reference in New Issue
Block a user