-
Notifications
You must be signed in to change notification settings - Fork 21
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
Add Python bindings coverage testing. #253
Comments
Agreed, but not sure how. Most of the code is generated and will account for lots of edge cases, I'm guessing. Really the only thing we want to check is:
Someone'll have to do some googling to see what the SWIG people have come up with! |
I was thinking that we would want to check that all methods that are exposed are used at least once. Not sure how we would go about testing for the presence of a docstring?
maybe iterating all available methods and checking |
I agree that having coverage testing to make sure the full libCellML API is exposed and tested via the bindings. Perhaps checking docstrings can be part of a more comprehensive style checking/linting that we should also have one day - if such checking included API documentation then it would be safe to assume the docs make it through to the bindings? |
The full libCellML API is not exposed we do have to suppress some of the C++ API because the interpretation of the overloaded functions doesn't translate well. The documentation for bindings is manually put in place. |
I've added a test for missing docstrings, as part of the work checking/updating the imports: 2c306e1 |
Turns out it also works as an unofficial cover test: When the C++ API changes the Python API gets updated automatically, and this test will complain that the new Python class/function is undocumented. If this happens, it's very likely the class/function won't have a test either! |
With the (recent) addition of the Python bindings I think adding coverage testing on the bindings would be beneficial.
The text was updated successfully, but these errors were encountered: