Skip to content

Commit

Permalink
Skip all hypothesis health checks by default in CI runs. (rapidsai#5090)
Browse files Browse the repository at this point in the history
To avoid non-deterministic sporadic failures.

Authors:
  - Carl Simon Adorf (https://github.com/csadorf)
  - AJ Schmidt (https://github.com/ajschmidt8)
  - Dante Gama Dessavre (https://github.com/dantegd)

Approvers:
  - William Hicks (https://github.com/wphicks)

URL: rapidsai#5090
  • Loading branch information
csadorf authored Dec 17, 2022
1 parent 32f16a3 commit 38a15cb
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions python/cuml/tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,22 @@
# Add the import here for any plugins that should be loaded EVERY TIME
pytest_plugins = ("cuml.testing.plugins.quick_run_plugin")

CI = os.environ.get("CI") in ("true", "1")


# Configure hypothesis profiles

HEALTH_CHECKS_SUPPRESSED_BY_DEFAULT = \
hypothesis.HealthCheck.all() if CI else [
hypothesis.HealthCheck.data_too_large,
hypothesis.HealthCheck.too_slow,
]

hypothesis.settings.register_profile(
name="unit",
parent=hypothesis.settings.get_profile("default"),
max_examples=20,
suppress_health_check=[
hypothesis.HealthCheck.data_too_large,
],
suppress_health_check=HEALTH_CHECKS_SUPPRESSED_BY_DEFAULT,
)

hypothesis.settings.register_profile(
Expand Down

0 comments on commit 38a15cb

Please sign in to comment.