-
Notifications
You must be signed in to change notification settings - Fork 297
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
Introduce an interface to SymSpell class to simplify mocking/testing #59
Comments
I see your point. But both Javascript and Python don't support the interface concept, while they are the most actively used ports of SymSpell. And even in the other languages probably not all developers are familiar with that concept. This would lead to fewer or more deviating ports. |
What about making methods virtual then as that would allow mocking too? |
At the moment we're forced to writing our own wrappers around SymSpell that would allow mocking the class in our unit tests.
A predefined interface (or at least virtual attributes on most of the compute-intensive methods) would remove this requirement.
P.S. I'm happy with doing a pull request in case it is an acceptable change
The text was updated successfully, but these errors were encountered: