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

Unit tests for installable plugins #226

Closed
simonw opened this issue Apr 19, 2018 · 2 comments
Closed

Unit tests for installable plugins #226

simonw opened this issue Apr 19, 2018 · 2 comments

Comments

@simonw
Copy link
Owner

simonw commented Apr 19, 2018

I'd like more thorough unit test coverage of the plugins mechanism - in particular for installable plugins.

I think I can do this while still having the code live in the same repo, by creating a subdirectory in tests/example_plugin with its own setup.py and then running python setup.py install as part of the test runner.

I imagine I will need to bump the version number every time I change the plugin in case someone runs the test again in the same virtual environment.

If that doesn't work I can instead ship a datasette-plugins-tests two to PyPI and add that as a tests_require dependency.

Refs #14

@simonw
Copy link
Owner Author

simonw commented Jun 23, 2019

The mechanism I described here - having a tests/example_plugin folder - is probably the right solution for #517

@simonw
Copy link
Owner Author

simonw commented Nov 24, 2020

This is well handled now: https://github.com/simonw/datasette/tree/0.51.1/tests/plugins

@simonw simonw closed this as completed Nov 24, 2020
@simonw simonw added the tests label Nov 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant