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

Fortran Tests #82

Closed
Tracked by #74
benegee opened this issue Aug 22, 2023 · 1 comment · Fixed by #89
Closed
Tracked by #74

Fortran Tests #82

benegee opened this issue Aug 22, 2023 · 1 comment · Fixed by #89

Comments

@benegee
Copy link
Collaborator

benegee commented Aug 22, 2023

Unfortunately Fortran is not natively supported by google test. A way around would be to write a Fortran program testing everything that is currently covered by the C-tests, write an interface to this function, and call it from a C++ google test.
It feels a little strange though, because we would call an interface function to Fortran, which would then call interface functions to C.

Alternatively, provided we keep running our examples, we could make sure that the examples use all of the provided Fortran functions.

The latter however seems not straightforward as apparently the Fortran interface calls are not considered in the coverage reports.

Originally posted by @bgeihe in #73 (comment)

@benegee
Copy link
Collaborator Author

benegee commented Aug 22, 2023

There are some Fortran unit testing frameworks, as listed, e.g., here or here. However, I don't know any of them, so I can't give good recommendations.

We could also try to roll our own, e.g., to essentially code up 2-3 examples as tests, where we use the interface functions and verify the return values/functionality. Since we test the "external language <-> Julia" interaction already with the C code, we really only have to verify that the Fortran layer does not change anything while interacting with C, so I think it would be feasible to do it using manually coded tests.

Originally posted by @sloede in #73 (comment)

This was referenced Aug 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant