From e3bb7afa1db9a2a8369da02c2a4a094c83f53da5 Mon Sep 17 00:00:00 2001 From: Robert Date: Fri, 6 Dec 2024 10:30:24 +0000 Subject: [PATCH] Updated CONTRIBUTING.md --- CONTRIBUTING.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index aecc9b7d7..e542782d2 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -34,9 +34,15 @@ errors, the commit will fail and you will see the changes that need to be made. We use `pytest` to run tests. Because `alibi` uses some TensorFlow 1.x constructs, to run all tests you need to invoke `pytest` twice as follows: ```bash -pytest -m tf1 alibi -pytest -m "not tf1 alibi" +TF_USE_LEGACY_KERAS=1 pytest -m "tf1" alibi +pytest -m "not tf1" alibi ``` + +or run directly: +```bash +make test +``` + [see also here](https://github.com/SeldonIO/alibi/blob/4d4f49e07263b20a25f552a8485844dc12281074/.github/workflows/ci.yml#L46-L47). It is not necessary to run the whole test suite locally for every PR as this can take a long time, it is enough to run `pytest` only on the affected test files or test functions. The whole test suite is run in CI on every PR.