Skip to content

Commit

Permalink
Moved requirements to their dedicated folders
Browse files Browse the repository at this point in the history
  • Loading branch information
heuer committed Oct 25, 2023
1 parent 2b9e2c8 commit b105c1b
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- name: Install dependencies
run: |
sudo apt -y install libzbar0
pip install -r requirements-testing.txt
pip install -r tests/requirements.txt
pip install setuptools
pip install flake8
pip install mypy
Expand Down
2 changes: 1 addition & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ sphinx:

python:
install:
- requirements: requirements-rtd.txt
- requirements: docs/requirements.txt
File renamed without changes.
8 changes: 4 additions & 4 deletions noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,18 @@
import shutil
import nox

_PY_VERSIONS = ('2.7', '3.7', '3.8', '3.9', '3.10', '3.11', 'pypy3')
_PY_VERSIONS = ('3.7', '3.8', '3.9', '3.10', '3.11', 'pypy3')
_PY_DEFAULT_VERSION = '3.11'

nox.options.sessions = ['test-2.7', 'test-{}'.format(_PY_DEFAULT_VERSION), 'test-pypy3']
nox.options.sessions = ['test-{}'.format(_PY_DEFAULT_VERSION), 'test-pypy3']


@nox.session(python=_PY_VERSIONS)
def test(session):
"""\
Run test suite.
"""
session.install('-Ur', 'requirements-testing.txt')
session.install('-Ur', 'tests/requirements.txt')
session.install('.')
session.run('py.test')

Expand All @@ -37,7 +37,7 @@ def docs(session):
"""\
Build the documentation.
"""
session.install('-Ur', 'requirements-rtd.txt')
session.install('-Ur', 'docs/requirements.txt')
output_dir = os.path.abspath(os.path.join(session.create_tmp(), 'output'))
shutil.rmtree(output_dir, ignore_errors=True)
doctrees, html, man = map(partial(os.path.join, output_dir), ['doctrees', 'html', 'man'])
Expand Down
6 changes: 0 additions & 6 deletions requirements-testing.txt

This file was deleted.

5 changes: 5 additions & 0 deletions tests/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Requirements to run the tests
pytest
pytest-cov
pypng~=0.0.20
pyzbar~=0.1.8

0 comments on commit b105c1b

Please sign in to comment.