Skip to content

Commit

Permalink
ruff ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
jhkennedy committed Nov 6, 2024
1 parent e4f101f commit b1f1e52
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ def tests(session: nox.Session) -> None:
*session.posargs,
)


@nox.session(name="test-min-deps", python="3.9", venv_backend="uv")
def test_min_deps(session: nox.Session) -> None:
"""Run the unit tests using the lowest compatible version of all direct dependencies."""
Expand All @@ -43,7 +44,6 @@ def test_min_deps(session: nox.Session) -> None:
)



@nox.session(name="integration-tests")
def integration_tests(session: nox.Session) -> None:
"""Run the integration tests."""
Expand Down
9 changes: 4 additions & 5 deletions tests/integration/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,13 @@ def pytest_sessionfinish(session, exitstatus):
# want to defer to original pytest behavior.
return


failure_rate = (100.0 * session.testsfailed) / session.testscollected
if failure_rate <= ACCEPTABLE_FAILURE_RATE:
status_code = os.environ.get('EARTHACCESS_ALLOWABLE_FAILURE_STATUS_CODE', 99)
status_code = os.environ.get("EARTHACCESS_ALLOWABLE_FAILURE_STATUS_CODE", 99)
warn(
f'\nWARNING: The integration test suite has returned {status_code} because the '
'failure rate was less than a hardcoded threshold. For more details see:\n'
'tests/integration/conftest.py.'
f"\nWARNING: The integration test suite has returned {status_code} because the "
"failure rate was less than a hardcoded threshold. For more details see:\n"
"tests/integration/conftest.py."
)
session.exitstatus = status_code

Expand Down

0 comments on commit b1f1e52

Please sign in to comment.