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
test the stand alone programs listed in the README.md #67
Comments
It's an interesting idea. I wonder if it might be more trouble than it's worth, though. |
maybe... but it would simultaneously increase test coverage... should just be one or two lines of sed or awk. |
Could we have a specific keyword or comment flag in the code that we would use to indicate that we want this behavior? (or better yet, a comment in the Also: I think we could do it with the wiki maybe... it could just clone https://github.com/jacobwilliams/json-fortran.wiki.git and then process all the |
I have a good, easy working example…. and yea, that’s not a bad idea about cloning the wiki. As far as I know there is no way to put comments in the README.md file that don’t get printed—but never fear! Right now it will only attempt to extract full “program” units, and just skip over all other code. To make my life easy, I just fetch http://people.sc.fsu.edu/~jburkardt/f_src/extract/extract.f90 and compile it on travis, and use it to extract any full programs in the README.md, so I don’t have to mess around with awk or sed. So for the README.md it just extracts example1 and example2, and skips over all the other embedded code. |
- Fixes jacobwilliams#67 compile and test example code from README.md - Small bug fix to dynamically computing the number of digits for real format edit descriptors - ceiling( log10( ... --> floor( 1 + log10( ... - consider the case when the number in question is a power of 10 e.g. 100 has 3 digits
- Fixes jacobwilliams#67 compile and test example code from README.md - Small bug fix to dynamically computing the number of digits for real format edit descriptors - ceiling( log10( ... --> floor( 1 + log10( ... - consider the case when the number in question is a power of 10 e.g. 100 has 3 digits
- Fixes jacobwilliams#67 compile and test example code from README.md - Small bug fix to dynamically computing the number of digits for real format edit descriptors - ceiling( log10( ... --> floor( 1 + log10( ... - consider the case when the number in question is a power of 10 e.g. 100 has 3 digits
- Fixes jacobwilliams#67 compile and test example code from README.md - Small bug fix to dynamically computing the number of digits for real format edit descriptors - ceiling( log10( ... --> floor( 1 + log10( ... - consider the case when the number in question is a power of 10 e.g. 100 has 3 digits
Genius! |
I’m thinking of adding a few lines to build.sh that will pull out an fortran program source listings in the README.md and dump them into
src/tests/jf_test_<program_name>.f90
to get compiled and run with the other unit tests. This would mean that the full programs listed in the README.md could be tested to ensure that they at least compile and run, without having to maintain duplicate copies of the source code. If they get moved to a wiki, as suggested in #66, however, I think we will lose the ability to do this. Thoughts?The text was updated successfully, but these errors were encountered: