Repository navigation
Fix XmlSchema and XSLT failing tests on Unix - #13645
Conversation
|
|
| */ | ||
|
|
||
| //[Variation(id = 11, Desc = "Load stylesheet with entity reference: Bug #68450 ")] | ||
| [ActiveIssue(9877)] |
There was a problem hiding this comment.
Interesting... this was passing before your change and is now failing?
There was a problem hiding this comment.
These tests are using checksum to verify the results, which can be flaky and turns out to fail all the time on Linux. There is an issue tracking this to rewrite these tests to not use checksum anymore.
| } | ||
|
|
||
| //[Variation("Load with \"\\\\\"")] | ||
| [PlatformSpecific(TestPlatforms.Windows)] //Not a valid path on Unix |
There was a problem hiding this comment.
Not a valid path on Unix
It actually is valid on Unix... and that's the problem for this test, right? It's expecting an invalid path?
There was a problem hiding this comment.
Yes, I will fix that.
| } | ||
|
|
||
| _output.WriteLine("Exception not generated for invalid ouput destination"); | ||
| Assert.True(false); |
There was a problem hiding this comment.
Can we use Assert.Throws instead?
There was a problem hiding this comment.
(Looks like there are a bunch of other places that would apply, too, so maybe a subsequently cleanup)
There was a problem hiding this comment.
When these tests were ported from Desktop, the process of porting tests to Xunit was automated and it was only feasible to use Assert.True(false) in place of failures. As you mentioned, this is repeated in many places and since it's not high priority, I created issue https://github.com/dotnet/corefx/issues/13647 to track this cleanup task.
Resolves https://github.com/dotnet/corefx/issues/12789
Xslt and Schema tests were using file paths and wrong capitalization of file names which would work on Windows, but not on Unix-based platforms. This is fixed in this PR.
Some tests are also made windows-specific as they test cases specific to windows.
@danmosemsft @weshaggard @stephentoub