Skip to content

Commit

Permalink
update test script
Browse files Browse the repository at this point in the history
  • Loading branch information
PWZER committed Sep 29, 2021
1 parent 3be1508 commit 5549ee0
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 18 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/lint-and-pytest.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Python Package using Conda
name: tests

on: [push, pull_request]

Expand All @@ -15,6 +15,6 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
- run: python setup.py install
- run: pip install flake8 pytest requests uvicorn tornado flask falcon aiohttp bottle sanic quart starlette
- run: pip install flake8 -r test/requirements.txt
- run: flake8
- run: pytest -s test/
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
![tests](https://github.com/PWZER/swagger-ui-py/actions/workflows/lint-and-pytest.yml/badge.svg)

# swagger-ui-py
Swagger UI for Python web framework, such Tornado, Flask, Quart, aiohttp, Sanic and Falcon.

Expand Down
2 changes: 0 additions & 2 deletions requirements.txt

This file was deleted.

11 changes: 11 additions & 0 deletions test/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
pytest
requests
uvicorn
tornado
flask
falcon
aiohttp
bottle
sanic
quart
starlette
26 changes: 12 additions & 14 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,17 +1,15 @@
[tox]
envlist = py39,py38
envlist = py38,py39

[testenv]
deps =
pytest
requests
uvicorn
tornado
flask
falcon
aiohttp
bottle
sanic
quart
starlette
commands = pytest test/
extras = flake8, pytest

[testenv:flake8]
commands =
pip install flake8
flake8 .

[testenv:pytest]
commands =
pip install -r test/requirements.txt
pytest -s test/

0 comments on commit 5549ee0

Please sign in to comment.