Skip to content

Commit ea0f68b

Browse files
ko3n1gclaude
andcommitted
test(kubeflow): mock kube clients in cleanup-noop test
test_cleanup_noop_without_workdir_pvc constructed a KubeflowExecutor without the mock_k8s_clients fixture, so __post_init__ ran the real config.load_kube_config()/load_incluster_config() and crashed in CI (no kubeconfig). Request the fixture like every other executor test. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Signed-off-by: oliver könig <okoenig@nvidia.com>
1 parent 5184615 commit ea0f68b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

test/core/execution/test_kubeflow.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -510,7 +510,7 @@ def test_cleanup_pulls_results_when_workdir_pvc(self, workdir_executor):
510510
workdir_executor.cleanup("exp-id___trainer___test-job")
511511
mock_pull.assert_called_once_with("test-job")
512512

513-
def test_cleanup_noop_without_workdir_pvc(self):
513+
def test_cleanup_noop_without_workdir_pvc(self, mock_k8s_clients):
514514
e = KubeflowExecutor(image="test:latest")
515515
with patch.object(e, "pull_results") as mock_pull:
516516
e.cleanup("exp-id___trainer___test-job")

0 commit comments

Comments
 (0)