Skip to content
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

Replace Moq dependency with a different Mocking library #140

Closed
bacherfl opened this issue Aug 9, 2023 · 4 comments · Fixed by #141, #142 or #143
Closed

Replace Moq dependency with a different Mocking library #140

bacherfl opened this issue Aug 9, 2023 · 4 comments · Fixed by #141, #142 or #143

Comments

@bacherfl
Copy link
Contributor

bacherfl commented Aug 9, 2023

Due to the controversies around the Moq library (see https://github.com/moq/moq/issues/1372), we may want to consider switching to another mocking library, like e.g. NSubstitute to avoid any privacy issues.
[1] Contains an example of how this was done by another previous Moq user.

Note: Currently we are using v4.18 of Moq, and the controversial change has been introduced with v4.20 and above, so currently this repo is not directly affected by the change. However, we should not merge any renovate PRs bumping the Moq dependency

References:
[1] Afterlife-Guide/AppSettings.Merge#6

@askpt
Copy link
Member

askpt commented Aug 9, 2023

Is someone planning on picking it? Can look into replacing Moq with NSubstitute.

@Kavindu-Dodan
Copy link

I don't see any PRs yet, so @askpt feel free to open a PR with the change :)

@benjiro
Copy link
Member

benjiro commented Aug 11, 2023

The following remaining tests need to be converted

Hook_Hints_May_Be_Optional
When_Error_Occurs_In_Before_Hook_Should_Return_Default_Value
When_Error_Occurs_In_After_Hook_Should_Invoke_Error_Hook

@toddbaert
Copy link
Member

Now only:

Hook_Hints_May_Be_Optional
When_Error_Occurs_In_After_Hook_Should_Invoke_Error_Hook

remaining.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
5 participants