Skip to content

Commit

Permalink
Merge pull request #4 from PropelAuth/pytest-fix
Browse files Browse the repository at this point in the history
Make pytest-runner conditional
  • Loading branch information
andrew-propelauth authored Feb 22, 2023
2 parents 05d662e + 005efe8 commit 99dffd2
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,17 @@
from setuptools import find_packages, setup
import pathlib
import sys

HERE = pathlib.Path(__file__).parent
README = (HERE / "README.md").read_text()

# See https://pytest-runner.readthedocs.io/en/latest/#conditional-requirement
needs_pytest = {'pytest', 'test', 'ptr'}.intersection(sys.argv)
pytest_runner = ['pytest-runner'] if needs_pytest else []

setup(
name="propelauth-py",
version="3.0.1",
version="3.0.2",
description="A python authentication library",
long_description=README,
long_description_content_type="text/markdown",
Expand All @@ -16,7 +21,7 @@
author_email="[email protected]",
license="MIT",
install_requires=["pyjwt[crypto]>=2,<3", "requests"],
setup_requires=["pytest-runner"],
setup_requires=pytest_runner,
tests_require=["pytest==4.4.1"],
test_suite="tests",
)

0 comments on commit 99dffd2

Please sign in to comment.