1
0
mirror of https://github.com/pocketbase/pocketbase.git synced 2025-11-28 00:38:36 +02:00

added onlyVerified auth collection option

This commit is contained in:
Gani Georgiev
2023-12-06 11:57:04 +02:00
parent 865865fdeb
commit 31317df21c
43 changed files with 591 additions and 446 deletions

View File

@@ -83,6 +83,11 @@ func TestRecordAuthResponse(t *testing.T) {
t.Fatal(err)
}
unverfiedAuthRecord, err := app.Dao().FindRecordById("clients", "o1y0dd0spd786md")
if err != nil {
t.Fatal(err)
}
scenarios := []struct {
name string
record *models.Record
@@ -97,6 +102,11 @@ func TestRecordAuthResponse(t *testing.T) {
record: nonAuthRecord,
expectError: true,
},
{
name: "valid auth record but with unverified email in onlyVerified collection",
record: unverfiedAuthRecord,
expectError: true,
},
{
name: "valid auth record - without meta",
record: authRecord,