Skip to content

Commit 32a33a2

Browse files
committed
test: no skipping if cwltool or dirac-cwl-run not available
1 parent 636bc7d commit 32a33a2

2 files changed

Lines changed: 1 addition & 30 deletions

File tree

diracx-api/tests/test_job_wrapper_integration.py

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -15,25 +15,11 @@
1515
from pathlib import Path
1616
from unittest.mock import AsyncMock, MagicMock, patch
1717

18-
import pytest
19-
20-
# ---------------------------------------------------------------------------
21-
# Skip guards
22-
# ---------------------------------------------------------------------------
23-
24-
pytest.importorskip("cwltool", reason="cwltool not installed")
25-
26-
dirac_cwl_run = shutil.which("dirac-cwl-run")
27-
pytestmark = pytest.mark.skipif(
28-
dirac_cwl_run is None,
29-
reason="dirac-cwl-run not on PATH",
30-
)
31-
3218
# ---------------------------------------------------------------------------
3319
# Direct imports — all dependencies are available in the test environment
3420
# ---------------------------------------------------------------------------
35-
3621
import cwl_utils.parser.cwl_v1_2 as _cwl_v1_2 # noqa: E402
22+
import pytest
3723

3824
import diracx.api.job_wrapper as _jw_mod # noqa: E402
3925
from diracx.api.job_wrapper import JobWrapper # noqa: E402

diracx-cli/tests/test_executor_integration.py

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,11 @@
1212
from __future__ import annotations
1313

1414
import json
15-
import shutil
1615
import subprocess
1716
from pathlib import Path
1817

1918
import pytest
2019

21-
# Skip the whole module if cwltool is not available
22-
cwltool = pytest.importorskip("cwltool", reason="cwltool not installed")
23-
2420
# ---------------------------------------------------------------------------
2521
# Helpers
2622
# ---------------------------------------------------------------------------
@@ -48,11 +44,6 @@
4844
"""
4945

5046

51-
def _skip_if_no_dirac_cwl_run():
52-
if not shutil.which("dirac-cwl-run"):
53-
pytest.skip("dirac-cwl-run not found on PATH")
54-
55-
5647
def _run(args: list[str], cwd: Path, timeout: int = 120) -> subprocess.CompletedProcess:
5748
return subprocess.run(
5849
args,
@@ -74,8 +65,6 @@ def test_basic_execution_with_replica_map(tmp_path):
7465
Proves: mypyc patch → executor init → replica map loading → LFN
7566
resolution → CWL execution → output file produced.
7667
"""
77-
_skip_if_no_dirac_cwl_run()
78-
7968
# 1. Create a local input file with known content
8069
input_content = "hello from integration test\n"
8170
local_input = tmp_path / "local_input.txt"
@@ -148,8 +137,6 @@ def test_execution_without_replica_map(tmp_path):
148137
Proves that baseline CWL execution works through the dirac-cwl-run entry
149138
point even when no replica map is provided.
150139
"""
151-
_skip_if_no_dirac_cwl_run()
152-
153140
# 1. Create a local input file
154141
input_content = "baseline cwl execution test\n"
155142
local_input = tmp_path / "local_input.txt"
@@ -204,8 +191,6 @@ def test_sb_reference_in_replica_map(tmp_path):
204191
The SB: key in the replica map is mapped to a local file. Proves that
205192
sandbox references are handled correctly through the replica map.
206193
"""
207-
_skip_if_no_dirac_cwl_run()
208-
209194
# 1. Create the real local file the SB: entry will point to
210195
input_content = "sandbox file content for integration test\n"
211196
local_file = tmp_path / "extracted_helper.txt"

0 commit comments

Comments
 (0)