roslyn-sdk
roslyn-sdk copied to clipboard
Unequal content leads to mismatching source list
XUnit. When the generated source code from a generator and the expected source code has the exact same structure and filenames but the contents are different, the test fails with "Expected source file list to match" despite the source file list being the same. Furthermore, the differing files in the message is often equal in content. For example, all of the files apart from PotatoSoup.cs(PotatoSoup was intentionally written as PottoSoup) have the same content, but the message says it's TomatoSoup.cs that doesn't match. The files and their contents are available at https://github.com/Arthri/dm01
Expected source file list to match
Sougen\Sougen.SoupGenerator\Soup.cs
Sougen\Sougen.SoupGenerator\CarrotSoup.cs
+Sougen\Sougen.SoupGenerator\TomatoSoup.cs
Sougen\Sougen.SoupGenerator\PotatoSoup.cs
-Sougen\Sougen.SoupGenerator\TomatoSoup.cs
Sougen\Sougen.SoupGenerator\CelerySoup.cs
Sougen\Sougen.SoupGenerator\GarlicSoup.cs
Sougen\Sougen.SoupGenerator\LentilSoup.cs
A repo containing the repro is available here https://github.com/Arthri/dm01 , the test class is named SoupGeneratorTests
I believe this is fixed #988. Can you update to 1.1.2-beta1.23115.1 and let me know if the problem still occurs?
The issue still persists as of 1.1.2-beta1.23115.1. I've also updated the repo to that version
💭 Interesting. I'm not really sure how to fix this without penalizing other scenarios.