Skip to content

Commit

Permalink
Moved extras_require to setup.cfg
Browse files Browse the repository at this point in the history
  • Loading branch information
alexbalakirev committed May 3, 2024
1 parent fed9b7e commit 8129125
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 41 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install .[gh]
python -m pip install .[test,flake8,tox_gh,tox]
- name: Test with tox
run: |
tox -e
tox run
env:
CORBADO_BACKEND_API: ${{ secrets.CORBADO_BACKEND_API }}
CORBADO_API_SECRET: ${{ secrets.CORBADO_API_SECRET }}
Expand Down
1 change: 1 addition & 0 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
-e .[test,flake8,tox]
1 change: 1 addition & 0 deletions requirements-gh.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
-e .[test,flake8,tox_gh,tox]
1 change: 1 addition & 0 deletions requirements-test.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
-e .[test]
25 changes: 24 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,27 @@
python-tag = py3

[metadata]
license_file = LICENSE
license_file = LICENSE

[options.extras_require]
test =
pytest~=7.1.3
pytest-cov>=2.8.1
pytest-randomly>=3.12.0

flake8 =
flake8>=7.0.0
pep8-naming # naming conventions check
flake8-builtins
flake8-bugbear
flake8-isort # check if import is sorted
darglint
flake8-bandit # security check
flake8-return
flake8-docstrings>=1.7.0

tox_gh =
tox-gh-actions

tox = tox>=4.0.0

21 changes: 0 additions & 21 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,21 +52,6 @@
"PyJWT",
"flask",
]
tox_requires = ["tox>=4.0.0"]
tox_gh_requires = ["tox-gh-actions"]
flake8_requires = [
"flake8",
"pep8-naming", # naming conventions check
"flake8-builtins",
"flake8-bugbear",
"flake8-isort", # check if import is sorted
"darglint",
"flake8-bandit", # security check
"flake8-return",
"flake8-docstring-checker", # enforce docstring
]

test_requires = ["pytest~=7.1.3", "pytest-cov>=2.8.1", "pytest-randomly>=3.12.0"]

setup(
name=NAME,
Expand All @@ -80,12 +65,6 @@
packages=find_namespace_packages(where="src"),
package_dir={"": "src"},
include_package_data=True,
extra_requires={
"gh": flake8_requires + tox_requires + test_requires + tox_gh_requires,
"dev": flake8_requires + tox_requires + test_requires,
"test": test_requires,
"flake8": flake8_requires,
},
classifiers=CLASSIFIERS,
long_description_content_type="text/markdown",
long_description=open(os.path.join(base_dir, "README.md"), encoding="utf-8").read(),
Expand Down
17 changes: 0 additions & 17 deletions test-requirements.txt

This file was deleted.

0 comments on commit 8129125

Please sign in to comment.