Skip to content

Standardize test namespaces to follow consistent naming pattern#502

Merged
mwaykole merged 3 commits intoopendatahub-io:mainfrom
mwaykole:compoent
Aug 8, 2025
Merged

Standardize test namespaces to follow consistent naming pattern#502
mwaykole merged 3 commits intoopendatahub-io:mainfrom
mwaykole:compoent

Conversation

@mwaykole
Copy link
Copy Markdown
Member

@mwaykole mwaykole commented Aug 8, 2025

Standardize test namespaces to follow consistent naming pattern which will help a new contributor

Signed-off-by: Milind Waykole <mwaykole@redhat.com>
@mwaykole mwaykole requested a review from a team as a code owner August 8, 2025 12:03
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Aug 8, 2025

📝 Walkthrough

Summary by CodeRabbit

  • Tests
    • Updated test namespace and parameter names across multiple test cases for consistency.
    • Removed an unused import in one test.
    • No changes to test logic or behavior.

Walkthrough

This change updates the "name" fields in test parameter dictionaries and string constants across multiple model serving test files. The modifications standardize namespace and test case names, often by prefixing them with "test-". No test logic, assertions, or control flow are altered, and only string literal values are changed.

Changes

Cohort / File(s) Change Summary
Model namespace name updates
tests/model_serving/model_server/components/kserve_dsc_deployment_mode/test_kserve_dsc_default_deployment_mode.py, tests/model_serving/model_server/components/model_mesh_kserve_co_exist/test_model_mesh_kserve_inference_co_exist.py, tests/model_serving/model_server/components/test_custom_resources.py, tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py, tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py, tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py, tests/model_serving/model_server/keda/test_isvc_keda_scaling_cpu.py, tests/model_serving/model_server/metrics/test_model_metrics.py, tests/model_serving/model_server/metrics/test_non_admin_users.py
Updated the "name" field in test parameter dictionaries to standardized, "test-" prefixed values for unprivileged model namespaces and test case identifiers.
Kueue namespace constant updates
tests/model_serving/model_server/kueue/test_kueue_isvc_raw.py, tests/model_serving/model_server/kueue/test_kueue_isvc_serverless.py
Changed the value of the NAMESPACE_NAME constant to a "test-" prefixed string in each file.
Import cleanup
tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py
Removed unused import of ModelFormat from utilities.constants.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Possibly related PRs

  • change namespace name for auth test #498: Both PRs focus on updating the "name" fields in pytest parameter dictionaries for unprivileged model namespaces in test files, standardizing namespace identifiers.

Suggested labels

size/s, ModelServing

Suggested reviewers

  • Raghul-M
  • adolfo-ab

Note

🔌 MCP (Model Context Protocol) integration is now available in Early Access!

Pro users can now connect to remote MCP servers under the Integrations page to get reviews and chat conversations that understand additional development context.

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai generate unit tests to generate unit tests for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@mwaykole mwaykole self-assigned this Aug 8, 2025
@mwaykole mwaykole added the Verified Verified pr in Jenkins label Aug 8, 2025
@github-actions github-actions bot added the size/s label Aug 8, 2025
@mwaykole mwaykole merged commit 9e37977 into opendatahub-io:main Aug 8, 2025
8 checks passed
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py (1)

70-70: Align multi-variant serverless name with the same pattern
Use “serverless” instead of “adv” to keep naming consistent within this file and across similar tests.

-            {"name": "test-adv-multi-update"},
+            {"name": "test-serverless-multi-update"},
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 02b6927 and dd60b37.

📒 Files selected for processing (11)
  • tests/model_serving/model_server/components/kserve_dsc_deployment_mode/test_kserve_dsc_default_deployment_mode.py (1 hunks)
  • tests/model_serving/model_server/components/model_mesh_kserve_co_exist/test_model_mesh_kserve_inference_co_exist.py (2 hunks)
  • tests/model_serving/model_server/components/test_custom_resources.py (1 hunks)
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py (2 hunks)
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py (1 hunks)
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py (1 hunks)
  • tests/model_serving/model_server/keda/test_isvc_keda_scaling_cpu.py (2 hunks)
  • tests/model_serving/model_server/kueue/test_kueue_isvc_raw.py (1 hunks)
  • tests/model_serving/model_server/kueue/test_kueue_isvc_serverless.py (1 hunks)
  • tests/model_serving/model_server/metrics/test_model_metrics.py (1 hunks)
  • tests/model_serving/model_server/metrics/test_non_admin_users.py (2 hunks)
🧰 Additional context used
🧠 Learnings (17)
📓 Common learnings
Learnt from: dbasunag
PR: opendatahub-io/opendatahub-tests#338
File: tests/model_registry/rbac/test_mr_rbac.py:24-53
Timestamp: 2025-06-06T12:22:57.057Z
Learning: In the opendatahub-tests repository, prefer keeping test parameterization configurations inline rather than extracting them to separate variables/constants, as it makes triaging easier by avoiding the need to jump between different parts of the file to understand the test setup.
Learnt from: dbasunag
PR: opendatahub-io/opendatahub-tests#354
File: tests/model_registry/rbac/conftest.py:166-175
Timestamp: 2025-06-16T11:25:39.599Z
Learning: In tests/model_registry/rbac/conftest.py, predictable names are intentionally used for test resources (like RoleBindings and groups) instead of random names. This design choice prioritizes exposing cleanup failures from previous test runs through name collisions rather than masking such issues with random names. The philosophy is that test failures should be observable and informative to help debug underlying infrastructure or cleanup issues.
Learnt from: Snomaan6846
PR: opendatahub-io/opendatahub-tests#444
File: tests/model_serving/model_runtime/mlserver/basic_model_deployment/test_mlserver_basic_model_deployment.py:48-714
Timestamp: 2025-07-16T12:20:29.672Z
Learning: In tests/model_serving/model_runtime/mlserver/basic_model_deployment/test_mlserver_basic_model_deployment.py, the same get_deployment_config_dict() function is called twice in each pytest.param because different fixtures (mlserver_inference_service and mlserver_serving_runtime) need the same deployment configuration data. This duplication is intentional to provide identical configuration to multiple fixtures.
📚 Learning: 2025-06-16T05:39:15.070Z
Learnt from: Snomaan6846
PR: opendatahub-io/opendatahub-tests#328
File: tests/model_serving/model_runtime/mlserver/conftest.py:182-189
Timestamp: 2025-06-16T05:39:15.070Z
Learning: The create_isvc function in utilities/inference_utils.py uses the parameter name `volumes_mounts` (with underscore), not `volume_mounts`, for passing volume mount configurations to InferenceService resources.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py
  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/metrics/test_non_admin_users.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py
  • tests/model_serving/model_server/keda/test_isvc_keda_scaling_cpu.py
📚 Learning: 2025-07-16T12:20:29.672Z
Learnt from: Snomaan6846
PR: opendatahub-io/opendatahub-tests#444
File: tests/model_serving/model_runtime/mlserver/basic_model_deployment/test_mlserver_basic_model_deployment.py:48-714
Timestamp: 2025-07-16T12:20:29.672Z
Learning: In tests/model_serving/model_runtime/mlserver/basic_model_deployment/test_mlserver_basic_model_deployment.py, the same get_deployment_config_dict() function is called twice in each pytest.param because different fixtures (mlserver_inference_service and mlserver_serving_runtime) need the same deployment configuration data. This duplication is intentional to provide identical configuration to multiple fixtures.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py
  • tests/model_serving/model_server/metrics/test_model_metrics.py
  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/components/kserve_dsc_deployment_mode/test_kserve_dsc_default_deployment_mode.py
  • tests/model_serving/model_server/components/model_mesh_kserve_co_exist/test_model_mesh_kserve_inference_co_exist.py
  • tests/model_serving/model_server/metrics/test_non_admin_users.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py
  • tests/model_serving/model_server/keda/test_isvc_keda_scaling_cpu.py
📚 Learning: 2025-06-11T16:40:11.593Z
Learnt from: israel-hdez
PR: opendatahub-io/opendatahub-tests#346
File: tests/model_serving/model_server/inference_graph/conftest.py:85-92
Timestamp: 2025-06-11T16:40:11.593Z
Learning: The helper `create_isvc` (used in tests/model_serving utilities) already waits until the created InferenceService reports Condition READY=True before returning, so additional readiness waits in fixtures are unnecessary.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py
📚 Learning: 2025-07-17T15:43:04.876Z
Learnt from: lugi0
PR: opendatahub-io/opendatahub-tests#446
File: tests/model_registry/conftest.py:579-591
Timestamp: 2025-07-17T15:43:04.876Z
Learning: In tests/model_registry/conftest.py, the db_service_1 and db_service_2 fixtures do not require the admin_client parameter for Service resource creation, despite the existing model_registry_db_service fixture using client=admin_client. This inconsistency was confirmed as intentional by user lugi0.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py
  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/components/kserve_dsc_deployment_mode/test_kserve_dsc_default_deployment_mode.py
  • tests/model_serving/model_server/metrics/test_non_admin_users.py
📚 Learning: 2025-07-17T15:42:04.167Z
Learnt from: lugi0
PR: opendatahub-io/opendatahub-tests#446
File: tests/model_registry/conftest.py:595-612
Timestamp: 2025-07-17T15:42:04.167Z
Learning: In tests/model_registry/conftest.py, the db_deployment_1 fixture (and similar duplicated resource fixtures) do not require the admin_client parameter or explicit dependencies on related fixtures like db_secret_1, db_pvc_1, and db_service_1, even though the original model_registry_db_deployment fixture includes these parameters.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py
  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/components/kserve_dsc_deployment_mode/test_kserve_dsc_default_deployment_mode.py
  • tests/model_serving/model_server/metrics/test_non_admin_users.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py
📚 Learning: 2025-06-06T12:22:57.057Z
Learnt from: dbasunag
PR: opendatahub-io/opendatahub-tests#338
File: tests/model_registry/rbac/test_mr_rbac.py:24-53
Timestamp: 2025-06-06T12:22:57.057Z
Learning: In the opendatahub-tests repository, prefer keeping test parameterization configurations inline rather than extracting them to separate variables/constants, as it makes triaging easier by avoiding the need to jump between different parts of the file to understand the test setup.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py
  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/components/kserve_dsc_deployment_mode/test_kserve_dsc_default_deployment_mode.py
  • tests/model_serving/model_server/components/model_mesh_kserve_co_exist/test_model_mesh_kserve_inference_co_exist.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py
📚 Learning: 2025-07-17T15:42:23.880Z
Learnt from: lugi0
PR: opendatahub-io/opendatahub-tests#446
File: tests/model_registry/conftest.py:733-770
Timestamp: 2025-07-17T15:42:23.880Z
Learning: In tests/model_registry/conftest.py, the model_registry_instance_1 and model_registry_instance_2 fixtures do not need explicit database dependency fixtures (like db_deployment_1, db_secret_1, etc.) in their function signatures. Pytest's dependency injection automatically handles the fixture dependencies when they reference db_name_1 and db_name_2 parameters. This is the correct pattern for these Model Registry instance fixtures.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py
  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/components/kserve_dsc_deployment_mode/test_kserve_dsc_default_deployment_mode.py
  • tests/model_serving/model_server/components/model_mesh_kserve_co_exist/test_model_mesh_kserve_inference_co_exist.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py
📚 Learning: 2025-06-05T10:05:17.642Z
Learnt from: adolfo-ab
PR: opendatahub-io/opendatahub-tests#334
File: tests/model_explainability/trustyai_service/test_trustyai_service.py:52-65
Timestamp: 2025-06-05T10:05:17.642Z
Learning: For TrustyAI image validation tests: operator image tests require admin_client, related_images_refs, and trustyai_operator_configmap fixtures, while service image tests would require different fixtures like trustyai_service_with_pvc_storage, model_namespace, and current_client_token.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py
  • tests/model_serving/model_server/metrics/test_model_metrics.py
  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/metrics/test_non_admin_users.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py
  • tests/model_serving/model_server/keda/test_isvc_keda_scaling_cpu.py
📚 Learning: 2025-06-16T11:25:39.599Z
Learnt from: dbasunag
PR: opendatahub-io/opendatahub-tests#354
File: tests/model_registry/rbac/conftest.py:166-175
Timestamp: 2025-06-16T11:25:39.599Z
Learning: In tests/model_registry/rbac/conftest.py, predictable names are intentionally used for test resources (like RoleBindings and groups) instead of random names. This design choice prioritizes exposing cleanup failures from previous test runs through name collisions rather than masking such issues with random names. The philosophy is that test failures should be observable and informative to help debug underlying infrastructure or cleanup issues.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py
  • tests/model_serving/model_server/metrics/test_model_metrics.py
  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/metrics/test_non_admin_users.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py
  • tests/model_serving/model_server/kueue/test_kueue_isvc_raw.py
  • tests/model_serving/model_server/keda/test_isvc_keda_scaling_cpu.py
📚 Learning: 2025-07-30T14:15:25.605Z
Learnt from: dbasunag
PR: opendatahub-io/opendatahub-tests#429
File: tests/model_registry/rbac/test_mr_rbac_sa.py:45-45
Timestamp: 2025-07-30T14:15:25.605Z
Learning: In tests/model_registry/rbac/test_mr_rbac_sa.py, bounds checking for model_registry_instance_rest_endpoint list access is not needed because upstream fixture validation already ensures endpoints exist before the tests execute. The Model Registry setup process validates endpoint availability, making additional bounds checks redundant.

Applied to files:

  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/metrics/test_non_admin_users.py
📚 Learning: 2025-07-04T00:17:47.799Z
Learnt from: dbasunag
PR: opendatahub-io/opendatahub-tests#401
File: tests/model_registry/rest_api/mariadb/conftest.py:89-110
Timestamp: 2025-07-04T00:17:47.799Z
Learning: In tests/model_registry/rest_api/mariadb/conftest.py, the model_registry_with_mariadb fixture should always use OAUTH_PROXY_CONFIG_DICT for the oauth_proxy parameter regardless of the is_model_registry_oauth parameter value, based on expected product behavior for MariaDB-backed ModelRegistry instances.

Applied to files:

  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/keda/test_isvc_keda_scaling_cpu.py
📚 Learning: 2025-07-17T15:42:26.275Z
Learnt from: lugi0
PR: opendatahub-io/opendatahub-tests#446
File: tests/model_registry/conftest.py:0-0
Timestamp: 2025-07-17T15:42:26.275Z
Learning: In tests/model_registry/conftest.py, the model_registry_instance_1 fixture (and similar duplicated Model Registry instance fixtures) do not require admin_client, db_deployment_1, or db_secret_1 parameters as explicit dependencies, even though these dependencies exist implicitly through the fixture dependency chain.

Applied to files:

  • tests/model_serving/model_server/components/test_custom_resources.py
  • tests/model_serving/model_server/metrics/test_non_admin_users.py
📚 Learning: 2025-07-17T15:41:54.284Z
Learnt from: lugi0
PR: opendatahub-io/opendatahub-tests#446
File: tests/model_registry/conftest.py:666-676
Timestamp: 2025-07-17T15:41:54.284Z
Learning: In tests/model_registry/conftest.py, the db_secret_1 and db_secret_2 fixtures do not require the admin_client parameter in their signatures, unlike some other Secret fixtures in the codebase. The user lugi0 confirmed this is the correct pattern for these specific fixtures.

Applied to files:

  • tests/model_serving/model_server/metrics/test_non_admin_users.py
  • tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py
📚 Learning: 2025-07-17T15:43:04.876Z
Learnt from: lugi0
PR: opendatahub-io/opendatahub-tests#446
File: tests/model_registry/conftest.py:579-591
Timestamp: 2025-07-17T15:43:04.876Z
Learning: In tests/model_registry/conftest.py, Service resources can be created without explicitly passing the admin_client parameter when using the context manager approach with "with Service()". The client parameter is optional for Service resource creation.

Applied to files:

  • tests/model_serving/model_server/metrics/test_non_admin_users.py
📚 Learning: 2025-06-03T06:31:46.614Z
Learnt from: Snomaan6846
PR: opendatahub-io/opendatahub-tests#325
File: utilities/manifests/common/grpc_predict_v2.proto:16-16
Timestamp: 2025-06-03T06:31:46.614Z
Learning: The grpc_predict_v2.proto file in utilities/manifests/common/ is from the official KServe V2 inference protocol specification and should not be modified. The package declaration "inference" is standardized and should remain unchanged even if it triggers Buf linting errors about package directory mismatch.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py
📚 Learning: 2025-06-03T06:31:46.614Z
Learnt from: Snomaan6846
PR: opendatahub-io/opendatahub-tests#325
File: utilities/manifests/common/grpc_predict_v2.proto:16-16
Timestamp: 2025-06-03T06:31:46.614Z
Learning: The grpc_predict_v2.proto file in utilities/manifests/common/ is from the official KServe V2 inference protocol specification and should not be modified. The package declaration "inference" is standardized and should remain unchanged even if it triggers Buf linting errors about package directory mismatch. This file should be excluded from Buf linting as it's a reference implementation.

Applied to files:

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py
🧬 Code Graph Analysis (2)
tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py (1)
utilities/constants.py (2)
  • ModelName (22-27)
  • RuntimeTemplates (65-77)
tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py (1)
utilities/constants.py (1)
  • RunTimeConfigs (234-238)
🔇 Additional comments (15)
tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py (2)

83-85: Timeout exception type likely inconsistent

Other tests use TimeoutExpiredError from timeout_sampler. Here you catch built-in TimeoutError, which may never be raised by TimeoutSampler.

Consider aligning to TimeoutExpiredError:

-        except TimeoutError:
+        except TimeoutExpiredError:
             LOGGER.error(f"Expected 1 pod to be running, but got {[_pod.name for _pod in pods]}")

Add the import near the top (outside this range):

from timeout_sampler import TimeoutSampler, TimeoutExpiredError

30-30: Unique test name usage confirmed — LGTM
Ran a repo-wide search for "test-raw-isvc-replicas" and found it only in

  • tests/model_serving/model_server/inference_service_configuration/test_isvc_replicas_update.py:30

No duplicate names detected; no further action needed.

tests/model_serving/model_server/kueue/test_kueue_isvc_raw.py (1)

21-21: Namespace constant rename verified — LGTM
Renamed NAMESPACE_NAME to "test-kueue-isvc-raw", matching the suite standard and DNS-1123 requirements. A ripgrep scan confirmed no remaining references to the old label.

• tests/model_serving/model_server/kueue/test_kueue_isvc_raw.py:21

tests/model_serving/model_server/kueue/test_kueue_isvc_serverless.py (1)

22-22: Confirmed no stale references to old namespace; LGTM

  • tests/model_serving/model_server/kueue/test_kueue_isvc_serverless.py: updated NAMESPACE_NAME to "test-kueue-isvc-serverless", no remaining references to "kueue-isvc-serverless-test"
tests/model_serving/model_server/keda/test_isvc_keda_scaling_cpu.py (2)

42-43: Param now uses the namespace constant — LGTM

Keeps the fixture-driven namespace aligned with metrics and names.


28-34: LGTM — Refactor ensures consistent namespace usage
Verification with ripgrep confirmed no lingering hard-coded “ovms-keda” references remain.

tests/model_serving/model_server/metrics/test_model_metrics.py (1)

31-31: No remaining references to kserve-tgis-metrics — all instances have been updated to "test-kserve-tgis-metrics".
LGTM.

tests/model_serving/model_server/components/kserve_dsc_deployment_mode/test_kserve_dsc_default_deployment_mode.py (1)

35-35: LGTM: standardized serverless DSC namespace name

The rename to "test-dsc-serverless" aligns with the PR goal. No logic impact observed.

tests/model_serving/model_server/components/test_custom_resources.py (1)

42-42: LGTM: standardized namespace for invalid models path scenario

The new "test-non-existing-models-path" name meets the convention; no functional changes.

tests/model_serving/model_server/metrics/test_non_admin_users.py (1)

17-17: LGTM: consistent "test-" prefixes for unprivileged user namespaces

Both renamed namespaces follow the standardized pattern; tests remain functionally identical.

Also applies to: 43-43

tests/model_serving/model_server/inference_service_configuration/test_isvc_pull_secret_updates.py (1)

8-8: LGTM: removed unused import and standardized namespace name

  • Import cleanup looks correct; ModelFormat is not referenced here.
  • "test-pull-secret-modelcar" follows the new naming convention.

Also applies to: 15-15

tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py (4)

35-35: Consistent raw namespace prefix — looks good
The "test-" + "raw" pattern aligns with the PR objective.


40-40: Consistent raw multi-variant naming — looks good
Matches the standardized pattern used above.


65-65: Serverless variant namespace standardized — looks good
Prefix and wording are consistent with the file’s context.


34-47: Namespace name uniqueness confirmed
Verified via ripgrep that each test namespace name is defined only in tests/model_serving/model_server/inference_service_configuration/test_isvc_env_vars_updates.py and does not appear elsewhere in the repo, so there is no risk of cross-test collisions. No changes required.

[
pytest.param(
{"name": "serverless-model-mesh-openvino", "modelmesh-enabled": True},
{"name": "test-mm-openvino", "modelmesh-enabled": True},
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Verification agent

🧩 Analysis chain

Avoid namespace collision: use distinct names for the two scenarios

Both parameterizations now target the same namespace ("test-mm-openvino"). This can cause cross-test interference or failures under parallel execution (xdist) and may mask bugs due to resource bleed-over between classes.

Recommend keeping standardized prefixes while preserving uniqueness per scenario.

Apply one of these diffs to restore isolation:

Option A (suffix with scenario order):

-            {"name": "test-mm-openvino", "modelmesh-enabled": True},
+            {"name": "test-mm-openvino-serverless-first", "modelmesh-enabled": True},
-            {"name": "test-mm-openvino", "modelmesh-enabled": True},
+            {"name": "test-mm-openvino-modelmesh-first", "modelmesh-enabled": True},

Option B (simple numeric suffixes):

-            {"name": "test-mm-openvino", "modelmesh-enabled": True},
+            {"name": "test-mm-openvino-1", "modelmesh-enabled": True},
-            {"name": "test-mm-openvino", "modelmesh-enabled": True},
+            {"name": "test-mm-openvino-2", "modelmesh-enabled": True},

To check for unintended reuse of "test-mm-openvino" across the repo:

Also applies to: 64-64


🏁 Script executed:

#!/bin/bash
rg -n --hidden --glob '!**/.git/**' $'{"name": "test-mm-openvino"\\s*,'

Length of output: 178


🏁 Script executed:

#!/bin/bash
# Search for any occurrences of the literal string "test-mm-openvino" across the repository
rg -n --hidden --glob '!**/.git/**' '"test-mm-openvino"' .

Length of output: 440


Ensure unique namespaces for parallel test scenarios

Both parameterizations in
tests/model_serving/model_server/components/model_mesh_kserve_co_exist/test_model_mesh_kserve_inference_co_exist.py
use the identical namespace "test-mm-openvino" (lines 25 and 64), risking resource collisions under xdist or delayed cleanup. Assign distinct names per scenario to preserve isolation.

Files & locations:

  • Line 25: first scenario
  • Line 64: second scenario

Suggested fix (numeric suffixes):

--- a/tests/model_serving/model_server/components/model_mesh_kserve_co_exist/test_model_mesh_kserve_inference_co_exist.py
@@ -22,7 +22,7 @@ @pytest.mark.parametrize(
-            {"name": "test-mm-openvino", "modelmesh-enabled": True},
+            {"name": "test-mm-openvino-1", "modelmesh-enabled": True},
@@ -61,7 +61,7 @@ @pytest.mark.parametrize(
-            {"name": "test-mm-openvino", "modelmesh-enabled": True},
+            {"name": "test-mm-openvino-2", "modelmesh-enabled": True},

This maintains your naming convention while guaranteeing test-level isolation.

🤖 Prompt for AI Agents
In
tests/model_serving/model_server/components/model_mesh_kserve_co_exist/test_model_mesh_kserve_inference_co_exist.py
at lines 25 and 64, the namespace "test-mm-openvino" is used in both
parameterizations, which can cause resource collisions during parallel test
runs. To fix this, rename the namespaces to be unique by adding numeric suffixes
or other distinct identifiers for each scenario, ensuring test isolation and
preventing conflicts.

@github-actions
Copy link
Copy Markdown

github-actions bot commented Aug 8, 2025

The following are automatically added/executed:

  • PR size label.
  • Run pre-commit
  • Run tox
  • Add PR author as the PR assignee
  • Build image based on the PR

Available user actions:

  • To mark a PR as WIP, add /wip in a comment. To remove it from the PR comment /wip cancel to the PR.
  • To block merging of a PR, add /hold in a comment. To un-block merging of PR comment /hold cancel.
  • To mark a PR as approved, add /lgtm in a comment. To remove, add /lgtm cancel.
    lgtm label removed on each new commit push.
  • To mark PR as verified comment /verified to the PR, to un-verify comment /verified cancel to the PR.
    verified label removed on each new commit push.
  • To Cherry-pick a merged PR /cherry-pick <target_branch_name> to the PR. If <target_branch_name> is valid,
    and the current PR is merged, a cherry-picked PR would be created and linked to the current PR.
  • To build and push image to quay, add /build-push-pr-image in a comment. This would create an image with tag
    pr-<pr_number> to quay repository. This image tag, however would be deleted on PR merge or close action.
Supported labels

{'/hold', '/wip', '/cherry-pick', '/verified', '/lgtm', '/build-push-pr-image'}

@github-actions
Copy link
Copy Markdown

github-actions bot commented Aug 8, 2025

Status of building tag latest: success.
Status of pushing tag latest to image registry: success.

@rhods-ci-bot rhods-ci-bot added lgtm-by-Raghul-M and removed Verified Verified pr in Jenkins labels Aug 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants