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
Tests: Protect RefRepos with mutex before reset #9856
Tests: Protect RefRepos with mutex before reset #9856
Conversation
b251880
to
ab0a992
Compare
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.
+1
@@ -79,12 +70,14 @@ public void HasChanges_updated_correctly() | |||
} | |||
} | |||
|
|||
[Ignore("Unstable UTF8EncodingSealed result")] |
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.
Perhaps ignore +UTF8EncodingSealed
?
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.
I really would like to know why this appear at this point, also when rolling back the changes...
What exact wording do you want?
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.
(Too short as too often) I meant to make the test accept both results.
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.
I do not see a way to create this encoding.
Would a regex match on the output encoding text be OK?
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.
I withdraw my proposal because I do not know enough about this topic.
BTW: For #9860, a BOM must be added to the English.xlf
.
Perhaps this is caused by different .NET patch levels of different AppVeyor instances.
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.
@RussKie Suggestions how to proceed with these tests?
(of course you are welcome to comment on the rest of the PR too...)
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.
BTW: For #9860, a BOM must be added to the
English.xlf
.
Perhaps this is caused by different .NET patch levels of different AppVeyor instances.
This sounds like dotnet/runtime#63585
ab0a992
to
8bc5d9d
Compare
Rebased on master as merge of #9805 required this update too. |
Is this happening for your locally or on AppVeyor? If it's failing locally, check dotnet/runtime#43295, may be it can give you some clues. |
Both, also when reverting. Maybe AppVeyor images differs, this is seen in #9680 too. |
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.
Let's take this as it is.
The ignored tests can be re-enabled when the dotnet/runtime bugs have been fixed, keyword UTF8EncodingSealed
.
Have you observed utf8 related tests failing on the vs2022 image? |
I have not used the vs2022 image myself |
Yes, I did but not always, e.g. https://ci.appveyor.com/project/gitextensions/gitextensions/builds/42471108#L370. |
Can this be merged, it is quite annoying that tests fail so often. For the disabled tests, it seem to be a coincidence that this occur after this change and I can drop that commit but it seems like it will continue occurring. |
8bc5d9d
to
c11cc90
Compare
c11cc90
to
cbabbb4
Compare
Proposed changes
Many tests (one out of four?) have failed recently:
https://ci.appveyor.com/project/gitextensions/gitextensions/builds/42433206
These issues occur when a ReferenceRepository is to be reset before next test case.
There seem to be some reuse of repos, parallel tests or repos that happen to use the same path.
The reason for the failure is unknown, but the reset is just a way to speed up the test and should not fail the test case.
So a try-catch to create a new repo is used.
Two tests became unstable after this, ignoring.
I have no clue why they occur after these changes, seem to be related to .net5
Edit: The initial version of this PR used a mutex to protect simultaneous changes but that did not prevent all changes.
That solution was inspired by https://github.com/GitTools/GitVersion/pull/2669/files
Test methodology
Rerun AppVeyor tests many times (manually).
Merge strategy
I agree that the maintainer squash merge this PR (if the commit message is clear).
✒️ I contribute this code under The Developer Certificate of Origin.