Skip to content

Commit 53be16b

Browse files
committed
fix failing cases
1 parent cf1b788 commit 53be16b

File tree

3 files changed

+7
-4
lines changed

3 files changed

+7
-4
lines changed

packages/gotrue/test/src/constants_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ void main() {
7272

7373
group('AuthChangeEvent', () {
7474
test('has correct enum values', () {
75-
expect(AuthChangeEvent.values.length, equals(7));
75+
expect(AuthChangeEvent.values.length, equals(8));
7676
expect(AuthChangeEvent.values, contains(AuthChangeEvent.initialSession));
7777
expect(
7878
AuthChangeEvent.values, contains(AuthChangeEvent.passwordRecovery));

packages/gotrue/test/src/helper_test.dart

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,11 +128,14 @@ void main() {
128128
returnsNormally);
129129
});
130130

131-
test('accepts valid UUID with different cases', () {
131+
test('accepts valid UUID with lowercase only', () {
132132
expect(() => validateUuid('550e8400-e29b-41d4-a716-446655440000'),
133133
returnsNormally);
134+
});
135+
136+
test('rejects UUID with uppercase characters', () {
134137
expect(() => validateUuid('550E8400-E29B-41D4-A716-446655440000'),
135-
returnsNormally);
138+
throwsArgumentError);
136139
});
137140

138141
test('accepts nil UUID', () {

packages/gotrue/test/src/types/user_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ void main() {
107107
test('handles null user_metadata', () {
108108
final json = <String, dynamic>{
109109
'id': '123',
110-
'app_metadata': {},
110+
'app_metadata': <String, dynamic>{},
111111
'user_metadata': null,
112112
'aud': 'authenticated',
113113
'created_at': '2023-01-01T00:00:00Z',

0 commit comments

Comments
 (0)