Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions packages/supabase_flutter/test/supabase_flutter_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -78,12 +78,12 @@ void main() {
});

test('emits exception when no auto refresh', () async {
// Give it a delay to wait for recoverSession to throw
await Future.delayed(const Duration(milliseconds: 100));

// The session recovery emits a `signedOut` event before the failure
// reaches the stream, and the subject replays only the latest event,
// so skip past any data events until the error arrives.
await expectLater(
Supabase.instance.client.auth.onAuthStateChange,
emitsError(isA<AuthException>()),
emitsThrough(emitsError(isA<AuthException>())),
);
});
});
Expand Down