Update test data cleanup to use user_id instead of subject in oauth_test.go

- Modified the cleanupTestData function to query by user_id, ensuring consistency with the updated user provider interface.
- This change enhances the accuracy of test data cleanup and aligns with recent refactoring efforts in user management.
This commit is contained in:
Max 2025-08-03 10:35:28 +08:00
parent 5301023cf2
commit 1dbcdd47d4

View file

@ -551,7 +551,7 @@ func cleanupTestData(t *testing.T, service *Service) {
// Clean up any remaining test data by patterns
_, err := m.DestroyWhere(model.QueryParam{
Wheres: []model.QueryWhere{
{Column: "subject", OP: "like", Value: "user-%"},
{Column: "user_id", OP: "like", Value: "user-%"},
},
})
if err != nil {