-
Notifications
You must be signed in to change notification settings - Fork 163
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix various failing CI tests #3535
Conversation
@@ -1328,7 +1328,7 @@ public void Session_WaitForUpload_CanBeCancelled() | |||
|
|||
sw.Stop(); | |||
|
|||
Assert.That(sw.ElapsedMilliseconds, Is.LessThan(5)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Even locally these two tests didn't pass all the time
@@ -1257,7 +1257,7 @@ private async Task<MongoClient.Collection<T>> GetCollection<T>(string appConfigT | |||
|
|||
SyncConfigurationBase config = appConfigType == AppConfigType.FlexibleSync ? GetFLXIntegrationConfig(user) : GetIntegrationConfig(user); | |||
|
|||
using var realm = await GetRealmAsync(config); | |||
using var realm = await GetRealmAsync(config, true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to wait for the schema to be synchronized, otherwise the call to the backends without the database name could raise an exception
// Unsubscribe and verify that it no longer raises user changed | ||
user.Changed -= OnUserChanged; | ||
|
||
tcs = new(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sometimes no TimeoutException
was raised at the end of the method on CI. I verified that actually we get two Changed
notifications, one for the custom data, and one for the user token refresh.
I suspect that sometimes the second notification was being raised after the new token completion source was created but before the unsubscription, that's why the timeout had no effect.
Pull Request Test Coverage Report for Build 8021119280Details
💛 - Coveralls |
* main: Fix various failing CI tests (#3535)
Fixes #3526