From a2c4f8e8d7e70c5fba87e4aef1a42d3e6341b045 Mon Sep 17 00:00:00 2001 From: aviruthen <91846056+aviruthen@users.noreply.github.com> Date: Thu, 11 Sep 2025 11:12:52 -0700 Subject: [PATCH 1/3] Code Coverage for Integ Tests --- tox.ini | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index e2fd7d55..d5231394 100644 --- a/tox.ini +++ b/tox.ini @@ -21,8 +21,11 @@ commands = [testenv:integ] description = Run integration tests +deps = + pytest-cov + -e . commands = - pytest test/integration_tests + pytest test/integration_tests --cov=sagemaker.hyperpod --cov-report=term-missing --cov-report=xml:coverage.xml [testenv:coverage] description = Run unit tests with coverage From 93bbd2ba5de1f07d9ea84cc98bd8c893e3c6e3e6 Mon Sep 17 00:00:00 2001 From: aviruthen <91846056+aviruthen@users.noreply.github.com> Date: Thu, 11 Sep 2025 13:25:36 -0700 Subject: [PATCH 2/3] Making sure target of coverage is correct --- setup.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.cfg b/setup.cfg index d048030d..a8cc0c29 100644 --- a/setup.cfg +++ b/setup.cfg @@ -50,7 +50,7 @@ xfail_strict = true addopts = --verbose --ignore=build/private - --cov hyperpod_cli + --cov sagemaker.hyperpod --cov-config setup.cfg --cov-report term-missing --cov-report html:build/hyperpod-documentation/coverage From a5076d9c0122fc2e68ad081c553c795cd82cce3c Mon Sep 17 00:00:00 2001 From: aviruthen <91846056+aviruthen@users.noreply.github.com> Date: Thu, 11 Sep 2025 14:50:05 -0700 Subject: [PATCH 3/3] Removing duplicate implementation --- setup.cfg | 4 ++-- tox.ini | 5 +---- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/setup.cfg b/setup.cfg index a8cc0c29..e883c540 100644 --- a/setup.cfg +++ b/setup.cfg @@ -59,8 +59,8 @@ addopts = --durations=5 # Default to colorful output --color=yes - # Uncomment to enforce a minimum code coverage threshold. - # --cov-fail-under 50 + # Enforce a minimum code coverage threshold + --cov-fail-under 50 testpaths = test looponfailroots = src test diff --git a/tox.ini b/tox.ini index d5231394..e2fd7d55 100644 --- a/tox.ini +++ b/tox.ini @@ -21,11 +21,8 @@ commands = [testenv:integ] description = Run integration tests -deps = - pytest-cov - -e . commands = - pytest test/integration_tests --cov=sagemaker.hyperpod --cov-report=term-missing --cov-report=xml:coverage.xml + pytest test/integration_tests [testenv:coverage] description = Run unit tests with coverage