Skip to content

Commit

Permalink
refactor: Remove pytest-durations dependency from testing and use…
Browse files Browse the repository at this point in the history
… native pytest option `--durations` (#2599)

packaging: Remove `testing` dependency on `pytest-durations`
  • Loading branch information
edgarrmondragon authored Aug 9, 2024
1 parent 22d4eae commit 39e1619
Show file tree
Hide file tree
Showing 5 changed files with 32 additions and 36 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@ singer-sdk = { version="~=0.39.1", extras = ["testing"] }
[tool.poetry.extras]
s3 = ["fs-s3fs"]

[tool.pytest.ini_options]
addopts = '--durations=10'

[tool.mypy]
python_version = "3.12"
warn_unused_configs = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ singer-sdk = { version="~=0.39.1", extras = ["testing"] }
[tool.poetry.extras]
s3 = ["fs-s3fs"]

[tool.pytest.ini_options]
addopts = '--durations=10'

[tool.mypy]
python_version = "3.12"
warn_unused_configs = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,13 @@ singer-sdk = { version="~=0.39.1", extras = ["testing"] }
[tool.poetry.extras]
s3 = ["fs-s3fs"]

[tool.pytest.ini_options]
addopts = '--durations=10'

[tool.mypy]
python_version = "3.12"
warn_unused_configs = true

[tool.ruff]
src = ["{{cookiecutter.library_name}}"]
target-version = "py38"
Expand Down
50 changes: 18 additions & 32 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 1 addition & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ pyarrow = { version = ">=13", optional = true }

# Testing dependencies installed as optional 'testing' extras
pytest = {version=">=7.2.1", optional = true}
pytest-durations = {version = ">=1.2.0", optional = true}

# installed as optional 'faker' extra
faker = {version = ">=22.5,<27.0", optional = true}
Expand All @@ -110,7 +109,6 @@ docs = [
s3 = ["fs-s3fs"]
testing = [
"pytest",
"pytest-durations"
]
parquet = ["numpy", "pyarrow"]
faker = ["faker"]
Expand Down Expand Up @@ -143,7 +141,7 @@ types-PyYAML = ">=6.0.12"
pytest-codspeed = ">=2.2.0"

[tool.pytest.ini_options]
addopts = '--ignore=singer_sdk/helpers/_simpleeval.py -m "not external"'
addopts = '--durations=10 --ignore=singer_sdk/helpers/_simpleeval.py -m "not external"'
filterwarnings = [
"error",
"ignore:Could not configure external gitlab tests:UserWarning",
Expand Down Expand Up @@ -251,7 +249,6 @@ DEP002 = [
"sphinx-reredirects",
# Plugins
"fs-s3fs",
"pytest-durations",
]

[tool.mypy]
Expand Down

0 comments on commit 39e1619

Please sign in to comment.