-
Notifications
You must be signed in to change notification settings - Fork 4.5k
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
Unit tests missing for MutexSecurity, SemaphoreSecurity, EventWaitHandleSecurity #43346
Comments
Hi, would you mind me working on this? I would love to pick it up. |
Hi @eugene-shcherbo yes, for sure - I assigned to you. |
Thank you @danmosemsft |
Hi @carlossanlop, @danmosemsft . I wonder if we want to cover with tests My opinion is that it would be good to test them, at least the tests would be like an additional documentation, but I'm not sure what issues addding the |
@carlossanlop is the code owner. I can say more generally: we try to test only through public API and we should do that if at all possible. Amongst other reasons that makes it easier to refactor the product code. In the rare instances where it isn't good enough, it is possible to use InternalsvisibleToAttribute but compiling selected product source files into the test assembly is preferable. This is the approach taken to test the |
@danmosemsft I get the idea, makes sense actually. Thank you for the answer, this is very useful to know. And apologizing for mentioning you in the question especially if I distracted you. |
You are welcome to mention me any time! |
Currently we only have one unit test file testing
MutexSecurity
, and contains only one unit test that verifies the parameterless constructor:runtime/src/libraries/System.Threading.AccessControl/tests/MutexSecurityTests.cs
Lines 6 to 16 in 6072e4d
We also need test classes to verify
SemaphoreSecurity
andEventWaitHandleSecurity
as well.The text was updated successfully, but these errors were encountered: