Skip to content
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

Disable some flaky tests and harden another one. #4376

Merged
merged 4 commits into from Feb 16, 2017

Conversation

kumpera
Copy link
Contributor

@kumpera kumpera commented Feb 14, 2017

The timer tests are disabled until they are rewritten to reflect real world behavior. Multiple reports including #52473.
ReRegisterForFinalizeTest was rewritten to use an auxilary thread to work around false pinning. Should fix #52406.

… and system timers.

The disabled tests assume perfect scheduling and non-coalescing system timers. Neither exists
on OSX Sierra, iOS or Android. This tests fail there regularly.
Thread.Sleep (1000);
Assert.IsTrue(bucket.count > 20, "#4");
using (Timer t = new Timer (o => Callback2 (o), bucket, 200, Timeout.Infinite)) {
bucket.mre.Wait (5000);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should do Assert.True (...)

Bucket bucket = new Bucket();

using (Timer t = new Timer (o => Callback2 (o), bucket, 10, 10)) {
bucket.mre.Wait (5000);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should do Assert.True (...)

using (Timer t = new Timer (o => Callback (o), bucket, 10, 10)) {
Thread.Sleep (500);
using (Timer t = new Timer (o => Callback2 (o), bucket, 10, 10)) {
bucket.mre.Wait (5000);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should do Assert.True (...)

using (Timer t = new Timer (o => Callback (o), bucket, 0, Timeout.Infinite)) {
Thread.Sleep (100);
using (Timer t = new Timer (o => Callback2 (o), bucket, 0, Timeout.Infinite)) {
bucket.mre.Wait (5000);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should do Assert.True (...)

@kumpera kumpera merged commit fd6829c into mono:master Feb 16, 2017
marek-safar pushed a commit that referenced this pull request Feb 16, 2017
Disable some flaky tests and harden another one.
kumpera added a commit that referenced this pull request Feb 22, 2017
picenka21 pushed a commit to picenka21/runtime that referenced this pull request Feb 18, 2022
Disable some flaky tests and harden another one.

Commit migrated from mono/mono@fd6829c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants