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 case executor for WSGI apps #31

Closed
Stranger6667 opened this issue Sep 9, 2019 · 0 comments · Fixed by #283
Closed

Test case executor for WSGI apps #31

Stranger6667 opened this issue Sep 9, 2019 · 0 comments · Fixed by #283
Assignees
Labels
Priority: High Important but not urgent Type: Feature New functionalities or enhancements

Comments

@Stranger6667
Copy link
Member

Stranger6667 commented Sep 9, 2019

Similar to what Flask has for testing - we don't have to use requests, we can work with the application directly. For this, we need to make this component interchangeable and write a one that will be able to execute schemathesis tests against an arbitrary WSGI app.

In general, this approach should be much faster than using a real network. The executor API design is up to discussion (feel free to propose any).

The main point of the issue is to simplify Schemathesis adoption - it is easier and faster to use a WSGI instance in certain frameworks like Flask or Django.

The implementation could be adopted from existing test clients, for example from Flask.

https://github.com/pallets/flask/blob/master/src/flask/testing.py#L115

Or, maybe we can use werkzeug directly - https://github.com/pallets/werkzeug/blob/master/src/werkzeug/test.py#L768

PEP: https://www.python.org/dev/peps/pep-3333/

@Stranger6667 Stranger6667 added Priority: Medium Planned for regular releases Type: Feature New functionalities or enhancements and removed enhancement labels Oct 2, 2019
@Stranger6667 Stranger6667 added this to the 0.10.0 milestone Oct 4, 2019
@Stranger6667 Stranger6667 removed this from the 0.10.0 milestone Oct 9, 2019
@Stranger6667 Stranger6667 added Priority: High Important but not urgent and removed Priority: Medium Planned for regular releases labels Dec 1, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority: High Important but not urgent Type: Feature New functionalities or enhancements
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants