You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 19, 2022. It is now read-only.
I'm writing some test cases for this library before extending it for my internal usage. Right now if you try to run multiple tests, the tests are all failed except one with the error message like below
Member ** is declared in another module and needs to be imported
However, they all pass if executed individually. The reason (I believe) is because the WeaverTypes class is static so the TypeReferences are imported from multiple assemblies when running
In multiple test cases. I implemented a fix by making WeaverTypes non-static and instantiate it as a member of ModuleWeaver and reference it from there instead of globally. If you decide to write unit tests some day, be aware of that pitfall in your code.
The text was updated successfully, but these errors were encountered:
I'm writing some test cases for this library before extending it for my internal usage. Right now if you try to run multiple tests, the tests are all failed except one with the error message like below
**: Usually one of these types.
However, they all pass if executed individually. The reason (I believe) is because the
WeaverTypes
class is static so theTypeReference
s are imported from multiple assemblies when runningIn multiple test cases. I implemented a fix by making
WeaverTypes
non-static and instantiate it as a member ofModuleWeaver
and reference it from there instead of globally. If you decide to write unit tests some day, be aware of that pitfall in your code.The text was updated successfully, but these errors were encountered: