Skip to content

Commit cfdb157

Browse files
committed
test(workbenches): introduce a new test for ImageStreams from trainer
The new 3 ImageStreams from trainer component were introduced in the product, we should test them similarly we do for the workbenches ImageStreams. Signed-off-by: Jan Stourac <jstourac@redhat.com>
1 parent 78bff54 commit cfdb157

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

tests/workbenches/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ workbenches/
1616

1717
### Current Test Suites
1818

19-
- **`test_imagestream_health.py`** - Validates that workbench ImageStreams are properly imported and resolved. Checks correct ImageStream counts, tag digest references (`@sha256:`), and `ImportSuccess` conditions for both notebook images (11 expected) and runtime images (7 expected)
19+
- **`test_imagestream_health.py`** - Validates that ImageStreams are properly imported and resolved. Uses compound label selectors (`opendatahub.io/notebook-image` or `opendatahub.io/runtime-image` combined with `platform.opendatahub.io/part-of`) to scope checks per component. Validates correct ImageStream counts, tag digest references (`@sha256:`), and `ImportSuccess` conditions for workbench notebook images (11 expected), workbench runtime images (7 expected), and trainer images (3 expected)
2020
- **`notebook-controller/test_spawning.py`** - Tests basic notebook creation via Notebook CR and validates pod creation. Also tests Auth proxy container resource customization via annotations
2121
- **`notebook-controller/test_custom_images.py`** - Validates custom workbench images contain required Python packages by spawning a workbench, installing any missing packages, and executing import verification
2222

tests/workbenches/test_imagestream_health.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,11 @@ def _validate_imagestreams_with_label(
186186
7,
187187
id="runtime_imagestreams",
188188
),
189+
pytest.param(
190+
"opendatahub.io/notebook-image=true,platform.opendatahub.io/part-of=trainer",
191+
3,
192+
id="trainer_imagestreams",
193+
),
189194
],
190195
)
191196
def test_workbench_imagestreams_health(

0 commit comments

Comments
 (0)