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

Test python code examples shown in guide during CI #169

Merged
merged 1 commit into from
Dec 21, 2021

Conversation

nhuet
Copy link
Contributor

@nhuet nhuet commented Dec 17, 2021

Test python code examples shown in guide

  • script/md2py.py create a python script from the python code blocks found in a markdown file
  • it uses docopt (to parse arguments) and commonmark (to parse markdown)
  • we run the resulting python script in CI

NB: if we launch the script with pytest instead of python, it is passing (pytest does not complain) but the exit code of pytest is 5 (no actual tests found) so that github action thinks that the test fails.

Fix #165.

@nhuet nhuet marked this pull request as draft December 17, 2021 09:34
@nhuet nhuet force-pushed the nh/test_howto_code branch 3 times, most recently from 4f1cc9d to 32ebd2b Compare December 17, 2021 11:43
@nhuet nhuet marked this pull request as ready for review December 17, 2021 11:45
.github/workflows/build.yml Outdated Show resolved Hide resolved
- script/md2py.py create a python script from the python code blocks found
in a markdown file
- it uses docopt (to parse arguments) and commonmark (to parse markdown)
- we run the resulting python script in CI

NB: if we launch the script with pytest instead of python, it is passing
(pytest does not complain) but the exit code of pytest is 5 (no actual tests found)
so that github action thinks that the test fails.

Fix airbus#165.
@galleon galleon merged commit 3c0af91 into airbus:master Dec 21, 2021
@nhuet nhuet deleted the nh/test_howto_code branch December 23, 2021 09:29
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 this pull request may close these issues.

Test the code in the guide and other pages
3 participants