(t *testing.T, db *gorm.DB)
| 83 | seedAdmissionMutationUser(t, store, "admission-delete-user", "alice") |
| 84 | }, |
| 85 | mutation: func(store *gormAPIStore) error { |
| 86 | found, err := store.DeleteUser("admission-delete-user", "alice") |
| 87 | if err == nil && !found { |
| 88 | return errors.New("deleted user was not found") |
| 89 | } |
| 90 | return err |
| 91 | }, |
| 92 | }, |
| 93 | } |
| 94 | |
| 95 | for _, tt := range tests { |
| 96 | t.Run(tt.name, func(t *testing.T) { |
| 97 | store := newPostgresConfigStore(t) |
| 98 | apiStore := newGormAPIStore(store).(*gormAPIStore) |
| 99 | tt.seed(t, store) |
| 100 | assertAdminMutationWaitsForAdmissionLock(t, store, tt.orgID, func() error { |
no test coverage detected