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: add webtest marker to tests that use the internet #2295

Merged
merged 1 commit into from Mar 21, 2023

Conversation

aucampia
Copy link
Member

Summary of changes

This is being done so that it is easier for downstream packagers to run the test
suite without requiring internet access.

To run only tests that does not use the internet, run pytest -m "not webtest".

The validation workflow validates that test run without internet access by
running the tests inside firejail --net=none.

Checklist

  • Checked that there aren't other open pull requests for
    the same change.
  • Checked that all tests and type checking passes.
  • Considered granting push permissions to the PR branch,
    so maintainers can fix minor issues and keep your PR up to date.

@aucampia aucampia force-pushed the iwana-20230319T2227-no_internet branch 4 times, most recently from 2986ca0 to 21d5693 Compare March 19, 2023 23:44
This is being done so that it is easier for downstream packagers to run the test
suite without requiring internet access.

To run only tests that does not use the internet, run `pytest -m "not webtest"`.

The validation workflow validates that test run without internet access by
running the tests inside `firejail --net=none`.

- Closes <RDFLib#2293>.
@aucampia aucampia force-pushed the iwana-20230319T2227-no_internet branch from 21d5693 to 3bf44f9 Compare March 19, 2023 23:47
@aucampia
Copy link
Member Author

Hopefully the coverage remains the same, if it does, then I guess we can go with this.

@coveralls
Copy link

Coverage Status

Coverage: 90.782%. Remained the same when pulling 3bf44f9 on aucampia:iwana-20230319T2227-no_internet into 7a05c15 on RDFLib:main.

@aucampia
Copy link
Member Author

Okay, coverage remains the same, so I think this is good to go.

I did this now, mainly so that it is less annoying for downstream to package our releases.

@aucampia aucampia added review wanted This indicates that the PR is ready for review ready to merge The PR will be merged soon if no further feedback is provided. labels Mar 19, 2023
@aucampia aucampia marked this pull request as ready for review March 19, 2023 23:56
@aucampia aucampia requested a review from a team March 19, 2023 23:56
Copy link

@ghost ghost left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@aucampia aucampia merged commit cfe6e37 into RDFLib:main Mar 21, 2023
23 checks passed
@aucampia aucampia deleted the iwana-20230319T2227-no_internet branch April 9, 2023 15:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready to merge The PR will be merged soon if no further feedback is provided. review wanted This indicates that the PR is ready for review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Provide an easy way to disable tests that use the internet
2 participants