<?xml version="1.0" encoding="utf-8"?><testsuites name="pytest tests"><testsuite name="pytest" errors="6" failures="2" skipped="29" tests="266" time="3835.710" timestamp="2026-10-29T22:51:31.900026+00:00" hostname="maas-group-test-7r8lb-e2e-maas-openshift-pod"><testcase classname="tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_rejected_outside_ai_tenants_namespace" time="9.781" /><testcase classname="tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_migrates_and_removes_legacy_tenant" time="40.358" /><testcase classname="tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_delete_cleans_maas_resources_and_preserves_user_objects" time="61.168" /><testcase classname="tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_default_aitenant_bootstraps_maas_tenant_config_without_gateway_mutation" time="2.485" /><testcase classname="tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_create_bootstrap_resources" time="59.122" /><testcase classname="tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_delete_releases_tenantconfig_finalizer" time="49.134" /><testcase classname="tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_derives_non_default_tenant_namespace" time="52.643" /><testcase classname="tests.test_api_keys.TestAPIKeyCRUD" name="test_create_api_key" time="109.313" /><testcase classname="tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_admin_can_revoke_any_user" time="0.978" /><testcase classname="tests.test_api_keys.TestAPIKeyExpiration" name="test_expiration_policy_boundaries[within-limit]" time="0.084" /><testcase classname="tests.test_api_keys.TestAPIKeyExpiration" name="test_expiration_policy_boundaries[at-limit]" time="0.100" /><testcase classname="tests.test_api_keys.TestAPIKeyExpiration" name="test_expiration_policy_boundaries[exceeds-limit]" time="0.085" /><testcase classname="tests.test_api_keys.TestAPIKeyExpiration" name="test_expiration_policy_boundaries[without-expiration]" time="0.089" /><testcase classname="tests.test_api_keys.TestAPIKeyExpiration" name="test_expiration_policy_boundaries[short-expiration]" time="0.083" /><testcase classname="tests.test_api_keys.TestAPIKeyModelInference" name="test_api_key_model_access_success" time="0.211" /><testcase classname="tests.test_api_keys.TestAPIKeyModelInference" name="test_invalid_api_key_rejected" time="0.052" /><testcase classname="tests.test_api_keys.TestAPIKeyModelInference" name="test_no_auth_header_rejected" time="0.041" /><testcase classname="tests.test_api_keys.TestAPIKeyModelInference" name="test_revoked_api_key_rejected" time="2.325" /><testcase classname="tests.test_api_keys.TestAPIKeyModelInference" name="test_api_key_chat_completions" time="0.095" /><testcase classname="tests.test_api_keys.TestAPIKeyRevocationE2E" name="test_double_revoke_returns_404" time="0.409" /><testcase classname="tests.test_api_keys.TestAPIKeyRevocationE2E" name="test_revoke_nonexistent_key_returns_404" time="0.102" /><testcase classname="tests.test_api_keys.TestAPIKeyRevocationE2E" name="test_revoke_then_create_new_key_works" time="0.469" /><testcase classname="tests.test_api_keys.TestAPIKeyRevocationE2E" name="test_individual_revoke_multiple_keys" time="0.578" /><testcase classname="tests.test_api_keys.TestAPIKeyRevocationE2E" name="test_revoke_keys_rejected_at_gateway" time="0.724" /><testcase classname="tests.test_api_keys.TestEphemeralKeyCleanup" name="test_cronjob_exists_and_configured" time="0.140" /><testcase classname="tests.test_api_keys.TestEphemeralKeyCleanup" name="test_cleanup_networkpolicy_exists" time="0.147" /><testcase classname="tests.test_api_keys.TestEphemeralKeyCleanup" name="test_create_ephemeral_key" time="0.279" /><testcase classname="tests.test_api_keys.TestEphemeralKeyCleanup" name="test_trigger_cleanup_preserves_active_keys" time="0.238"><skipped type="pytest.skip" message="Cannot find maas-api pod in odh-ai-gateway-infra: error: error executing jsonpath &quot;{.items[0].metadata.name}&quot;: Error executing template: array index out of bounds: index 0, length 0. Printing more information for debugging the template:&#10;&#09;template was:&#10;&#09;&#09;{.items[0].metadata.name}&#10;&#09;object given to jsonpath engine was:&#10;&#09;&#09;map[string]interface {}{&quot;apiVersion&quot;:&quot;v1&quot;, &quot;items&quot;:[]interface {}{}, &quot;kind&quot;:&quot;List&quot;, &quot;metadata&quot;:map[string]interface {}{&quot;resourceVersion&quot;:&quot;&quot;}}">/workspace/source/test/e2e/tests/test_api_keys.py:1429: Cannot find maas-api pod in odh-ai-gateway-infra: error: error executing jsonpath "{.items[0].metadata.name}": Error executing template: array index out of bounds: index 0, length 0. Printing more information for debugging the template:
	template was:
		{.items[0].metadata.name}
	object given to jsonpath engine was:
		map[string]interface {}{"apiVersion":"v1", "items":[]interface {}{}, "kind":"List", "metadata":map[string]interface {}{"resourceVersion":""}}</skipped></testcase><testcase classname="tests.test_api_keys.TestAPIKeySubscriptionPhases" name="test_create_key_for_active_subscription" time="14.453" /><testcase classname="tests.test_api_keys.TestAPIKeySubscriptionPhases" name="test_create_key_for_degraded_subscription" time="14.343" /><testcase classname="tests.test_api_keys.TestAPIKeyCRUD" name="test_list_api_keys" time="131.093" /><testcase classname="tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_by_subscription" time="15.505" /><testcase classname="tests.test_api_keys.TestAPIKeySubscriptionPhases" name="test_create_key_for_failed_subscription" time="12.284" /><testcase classname="tests.test_api_keys.TestAPIKeySubscriptionFilter" name="test_search_filters_by_subscription" time="28.822" /><testcase classname="tests.test_api_keys.TestAPIKeySubscriptionFilter" name="test_search_without_subscription_returns_all" time="0.678" /><testcase classname="tests.test_api_keys.TestAPIKeyLabels" name="test_search_api_keys_by_labels" time="0.433" /><testcase classname="tests.test_api_keys.TestAPIKeyLabels" name="test_labels_validation_errors" time="0.317" /><testcase classname="tests.test_api_keys.TestAPIKeyLabels" name="test_backward_compatibility_no_labels" time="0.516" /><testcase classname="tests.test_authpolicy_generation_stability.TestAuthPolicyGenerationStability" name="test_generation_does_not_increase_during_quiet_window" time="62.498" /><testcase classname="tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_own_keys" time="127.412" /><testcase classname="tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_dry_run" time="0.504" /><testcase classname="tests.test_config_tenant.TestConfigAnchorPresence" name="test_cluster_config_default_exists" time="0.572" /><testcase classname="tests.test_config_tenant.TestConfigAnchorPresence" name="test_cluster_config_not_terminating" time="0.193" /><testcase classname="tests.test_config_tenant.TestConfigTenantOwnership" name="test_default_aitenant_lists_config_owner_reference" time="0.153" /><testcase classname="tests.test_config_tenant.TestConfigTenantOwnership" name="test_tenant_config_lists_config_owner_reference" time="0.171" /><testcase classname="tests.test_config_tenant.TestConfigTenantOwnership" name="test_maas_controller_deployment_does_not_list_config_owner_reference" time="0.164" /><testcase classname="tests.test_gateway_filter_chain_praxis.TestGatewayFilterChainPraxis" name="test_no_listener_rejected" time="6.023" /><testcase classname="tests.test_gateway_filter_chain_praxis.TestGatewayFilterChainPraxis" name="test_payload_processing_precedes_router" time="0.001" /><testcase classname="tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyStructure" name="test_gateway_auth_policy_contract" time="0.478" /><testcase classname="tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyLifecycle" name="test_gateway_auth_rego_is_fixed_size" time="3.797" /><testcase classname="tests.test_api_keys.TestAPIKeyLabels" name="test_create_api_key_with_labels" time="0.512" /><testcase classname="tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyManagementEndpointAccess" name="test_management_rules_have_model_identity_guards" time="0.169" /><testcase classname="tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyManagementEndpointAccess" name="test_gateway_default_auth_scoped_if_present" time="0.001"><skipped type="pytest.skip" message="legacy gateway-default-auth is scoped to the shared default gateway">/workspace/source/test/e2e/tests/test_gateway_scoped_authpolicy.py:213: legacy gateway-default-auth is scoped to the shared default gateway</skipped></testcase><testcase classname="tests.test_guardrail_attachment" name="test_aiguardrail_crd_is_installed" time="0.167" /><testcase classname="tests.test_guardrail_attachment" name="test_installed_crd_carries_the_attachment_field[maassubscriptions.maas.opendatahub.io-guardrails]" time="0.167" /><testcase classname="tests.test_guardrail_attachment" name="test_installed_crd_carries_the_attachment_field[maastenantconfigs.maas.opendatahub.io-guardrails]" time="0.194" /><testcase classname="tests.test_guardrail_attachment" name="test_installed_crd_carries_the_attachment_field[aitenants.maas.opendatahub.io-guardrails]" time="0.169" /><testcase classname="tests.test_guardrail_attachment" name="test_installed_crd_carries_the_attachment_field[maasmodelrefs.maas.opendatahub.io-guardrails]" time="0.175" /><testcase classname="tests.test_guardrail_attachment" name="test_subscription_accepts_attachments_at_both_scopes" time="0.905" /><testcase classname="tests.test_guardrail_attachment" name="test_reference_namespace_is_pruned" time="0.527" /><testcase classname="tests.test_guardrail_attachment" name="test_attachment_list_is_bounded" time="0.170" /><testcase classname="tests.test_guardrail_attachment" name="test_check_names_must_be_dns_labels" time="0.326" /><testcase classname="tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyLifecycle" name="test_only_one_gateway_authpolicy_named_maas_gateway_auth" time="0.379" /><testcase classname="tests.test_model_identity_conflict.TestModelIdentityConflictDetection" name="test_colliding_model_names_flagged_then_resolved" time="92.989" /><testcase classname="tests.test_api_keys.TestAPIKeyAuthorization" name="test_admin_manage_other_users_keys" time="150.466" /><testcase classname="tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_by_subscription_forbidden_for_non_admin" time="0.427" /><testcase classname="tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_other_user_forbidden" time="152.404" /><testcase classname="tests.test_api_keys.TestAPIKeyAuthorization" name="test_non_admin_cannot_access_other_users_keys" time="144.621" /><testcase classname="tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_dry_run_by_subscription" time="15.749" /><testcase classname="tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_missing_scope_returns_400" time="0.445" /><testcase classname="tests.test_api_keys.TestAPIKeyCRUD" name="test_revoke_api_key" time="150.488" /><testcase classname="tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_combined_user_and_subscription" time="16.286" /><testcase classname="tests.test_authpolicy_generation_stability.TestAuthPolicyGenerationStability" name="test_no_rapid_resource_version_changes" time="60.500" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_empty_subscription_header_value" time="87.457" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_user_token_returns_all_models" time="131.420" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_multiple_distinct_models_in_subscription" time="34.581" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_api_key_scoped_to_subscription" time="108.739" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_response_schema_and_metadata" time="85.643" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_invalid_subscription_header_403" time="23.449" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_multiple_api_keys_different_subscriptions" time="25.114" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_api_key_with_deleted_subscription_403" time="40.545" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_api_key_with_inaccessible_subscription_403" time="119.399" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_user_token_with_subscription_header_filters" time="12.665" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_unauthenticated_request_401" time="4.065"><failure message="AssertionError: Expected 401 for unauthenticated request, got 500: Internal Server Error.&#10;  &#10;assert 500 == 401&#10; +  where 500 = &lt;Response [500]&gt;.status_code">self = &lt;test_models_endpoint.TestModelsEndpoint object at 0x7f6b509ebd10&gt;

    def test_unauthenticated_request_401(self):
        """
        Test: Request to /v1/models without Authorization header gets 401.
    
        Expected: HTTP 401 (authentication_error).
        """
        # Test: GET /v1/models WITHOUT Authorization header
        # Expected: 401 Unauthorized
        log.info("Testing: GET /v1/models without Authorization header")
        url = f"{_maas_api_url()}/v1/models"
        r = requests.get(
            url,
            timeout=TIMEOUT,
            verify=TLS_VERIFY,
        )
    
&gt;       assert r.status_code == 401, f"Expected 401 for unauthenticated request, got {r.status_code}: {r.text}"
E       AssertionError: Expected 401 for unauthenticated request, got 500: Internal Server Error.
E         
E       assert 500 == 401
E        +  where 500 = &lt;Response [500]&gt;.status_code

test/e2e/tests/test_models_endpoint.py:2216: AssertionError</failure></testcase><testcase classname="tests.test_multi_tenant_integration.TestMultiTenantIntegration" name="test_tenant_namespace_label_change_triggers_reconciliation" time="123.365" /><testcase classname="tests.test_multi_tenant_integration.TestMultiTenantIntegration" name="test_same_named_resources_across_tenants" time="205.141" /><testcase classname="tests.test_multi_tenant_integration.TestMultiTenantIntegration" name="test_full_tenant_lifecycle_create_to_delete" time="383.209" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_api_key_ignores_subscription_header" time="27.140" /><testcase classname="tests.test_multi_tenant_integration.TestMultiTenantIntegration" name="test_default_tenant_unaffected_by_multitenancy_enablement" time="140.844" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_deduplication_same_model_multiple_refs" time="157.626" /><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_access_denied_to_subscription_403" time="100.192"><error message="failed on setup with &quot;Failed: PREREQUISITE INVALID: MaaSModelRef 'simulator-w0-e57216' not Ready (phase=Unhealthy, endpoint=none). Wait for reconciliation or check controller logs.&quot;">cls = &lt;class 'test_models_endpoint.TestModelsEndpoint'&gt;

    @classmethod
    def setup_class(cls):
        """Validate test environment prerequisites before running any tests."""
        log.info("=" * 60)
        log.info("Validating /v1/models E2E Test Prerequisites")
        log.info("=" * 60)
    
        # Validate MODEL_REF exists and is Ready
        model = _get_cr("maasmodelref", MODEL_REF, MODEL_NAMESPACE)
        if not model:
            pytest.fail(f"PREREQUISITE MISSING: MaaSModelRef '{MODEL_REF}' not found in namespace '{MODEL_NAMESPACE}'. "
                       f"Ensure prow setup has created the model.")
    
        phase = model.get("status", {}).get("phase")
        endpoint = model.get("status", {}).get("endpoint")
        if phase != "Ready" or not endpoint:
&gt;           pytest.fail(f"PREREQUISITE INVALID: MaaSModelRef '{MODEL_REF}' not Ready "
                       f"(phase={phase}, endpoint={endpoint or 'none'}). "
                       f"Wait for reconciliation or check controller logs.")
E           Failed: PREREQUISITE INVALID: MaaSModelRef 'simulator-w0-e57216' not Ready (phase=Unhealthy, endpoint=none). Wait for reconciliation or check controller logs.

test/e2e/tests/test_models_endpoint.py:381: Failed</error></testcase><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_service_account_token_multiple_subs_with_header" time="0.001"><error message="failed on setup with &quot;Failed: PREREQUISITE INVALID: MaaSModelRef 'simulator-w0-e57216' not Ready (phase=Unhealthy, endpoint=none). Wait for reconciliation or check controller logs.&quot;">cls = &lt;class 'test_models_endpoint.TestModelsEndpoint'&gt;

    @classmethod
    def setup_class(cls):
        """Validate test environment prerequisites before running any tests."""
        log.info("=" * 60)
        log.info("Validating /v1/models E2E Test Prerequisites")
        log.info("=" * 60)
    
        # Validate MODEL_REF exists and is Ready
        model = _get_cr("maasmodelref", MODEL_REF, MODEL_NAMESPACE)
        if not model:
            pytest.fail(f"PREREQUISITE MISSING: MaaSModelRef '{MODEL_REF}' not found in namespace '{MODEL_NAMESPACE}'. "
                       f"Ensure prow setup has created the model.")
    
        phase = model.get("status", {}).get("phase")
        endpoint = model.get("status", {}).get("endpoint")
        if phase != "Ready" or not endpoint:
&gt;           pytest.fail(f"PREREQUISITE INVALID: MaaSModelRef '{MODEL_REF}' not Ready "
                       f"(phase={phase}, endpoint={endpoint or 'none'}). "
                       f"Wait for reconciliation or check controller logs.")
E           Failed: PREREQUISITE INVALID: MaaSModelRef 'simulator-w0-e57216' not Ready (phase=Unhealthy, endpoint=none). Wait for reconciliation or check controller logs.

test/e2e/tests/test_models_endpoint.py:381: Failed</error></testcase><testcase classname="tests.test_namespace_scoping.TestMaaSAPIWatchNamespace" name="test_subscription_in_another_namespace_not_visible_to_api" time="0.000"><skipped type="pytest.skip" message="test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true">/workspace/source/test/e2e/tests/test_namespace_scoping.py:247: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="tests.test_namespace_scoping.TestMaaSControllerWatchNamespace" name="test_authpolicy_and_subscription_in_maas_subscription_namespace" time="0.000"><skipped type="pytest.skip" message="test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true">/workspace/source/test/e2e/tests/test_namespace_scoping.py:287: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="tests.test_namespace_scoping.TestMaaSControllerWatchNamespace" name="test_authpolicy_and_subscription_in_another_namespace" time="0.000"><skipped type="pytest.skip" message="test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true">/workspace/source/test/e2e/tests/test_namespace_scoping.py:324: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="tests.test_namespace_scoping.TestModelRef" name="test_auth_policy_model_ref" time="0.000"><skipped type="pytest.skip" message="test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true">/workspace/source/test/e2e/tests/test_namespace_scoping.py:382: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="tests.test_namespace_scoping.TestModelRef" name="test_subscription_model_ref" time="0.000"><skipped type="pytest.skip" message="test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true">/workspace/source/test/e2e/tests/test_namespace_scoping.py:456: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="tests.test_negative_security.TestAPIKeyManagementIsolation" name="test_api_key_cannot_mint_another_api_key" time="0.554" /><testcase classname="tests.test_negative_security.TestHeaderSpoofing" name="test_forged_identity_headers_rejected_on_key_mint[username-only]" time="0.892" /><testcase classname="tests.test_negative_security.TestHeaderSpoofing" name="test_forged_identity_headers_rejected_on_key_mint[group-only]" time="0.682" /><testcase classname="tests.test_negative_security.TestHeaderSpoofing" name="test_forged_identity_headers_rejected_on_key_mint[keyname-only]" time="0.710" /><testcase classname="tests.test_negative_security.TestHeaderSpoofing" name="test_forged_identity_headers_rejected_on_key_mint[identity-envelope]" time="0.633" /><testcase classname="tests.test_negative_security.TestHeaderSpoofing" name="test_forged_identity_headers_rejected_on_key_mint[admin-scope]" time="0.629" /><testcase classname="tests.test_negative_security.TestHeaderSpoofing" name="test_injected_identity_headers_rejected_on_inference" time="0.350" /><testcase classname="tests.test_negative_security.TestHeaderSpoofing" name="test_duplicate_subscription_headers_ignored" time="9.145" /><testcase classname="tests.test_negative_security.TestExpiredKeyRejection" name="test_expired_key_rejected_at_gateway" time="7.514" /><testcase classname="tests.test_negative_security.TestCrossModelAccess" name="test_key_cannot_access_model_outside_subscription" time="0.773" /><testcase classname="tests.test_negative_security.TestMissingModelRef" name="test_subscription_with_nonexistent_model_ref" time="14.072" /><testcase classname="tests.test_negative_security.TestMissingModelRef" name="test_authpolicy_with_nonexistent_model_ref" time="61.075"><failure message="TimeoutError: MaaSAuthPolicy e2e-neg-ghost-policy-82f5834f did not reach phase 'Degraded' within 60s (last seen: phase=Pending, authPolicies=0 (ready=0))">self = &lt;test_negative_security.TestMissingModelRef object at 0x7fdde7b3d6d0&gt;

    def test_authpolicy_with_nonexistent_model_ref(self):
        """MaaSAuthPolicy does not generate per-model AuthPolicies in gateway-only mode.
    
        Creates an auth policy referencing one valid model and one ghost model,
        waits for Degraded phase, then asserts that no legacy per-model
        AuthPolicies exist for either model.
        """
        suffix = uuid.uuid4().hex[:8]
        policy_name = f"e2e-neg-ghost-policy-{suffix}"
        ghost_model = f"nonexistent-model-{suffix}"
    
        try:
            _create_test_auth_policy(
                policy_name,
                [MODEL_REF, ghost_model],
                groups=["system:authenticated"],
            )
    
&gt;           _wait_for_maas_auth_policy_phase(policy_name, "Degraded", timeout=60, require_auth_policies=False)

test/e2e/tests/test_negative_security.py:578: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

name = 'e2e-neg-ghost-policy-82f5834f', expected_phase = 'Degraded'
namespace = 'models-as-a-service', timeout = 60, require_auth_policies = False
require_enforced = True

    def _wait_for_maas_auth_policy_phase(name, expected_phase="Active", namespace=None, timeout=AUTHPOLICY_PHASE_TIMEOUT,
                                    require_auth_policies=False, require_enforced=True):
        """Wait for MaaSAuthPolicy to reach a specific phase.
    
        Args:
            name: Name of the MaaSAuthPolicy
            expected_phase: Phase to wait for (default: "Active")
            namespace: Namespace (defaults to _ns())
            timeout: Maximum wait time in seconds (default: 60)
            require_auth_policies: If True, requires authPolicies to be populated (default: False).
                                   Keep False for gateway-only AuthPolicy reconciliation.
            require_enforced: If True (default):
                - with require_auth_policies=True: all status.authPolicies entries must be ready
                - with require_auth_policies=False and expected_phase Active: also wait for the
                  gateway Kuadrant AuthPolicy (maas-gateway-auth) to be Accepted+Enforced
    
        Returns:
            The auth policy CR dict when the expected phase is reached
    
        Raises:
            TimeoutError: If MaaSAuthPolicy doesn't reach expected phase within timeout
        """
        namespace = namespace or _ns()
        deadline = time.time() + timeout
        log.info(f"Waiting for MaaSAuthPolicy {name} to reach phase '{expected_phase}' (timeout: {timeout}s)...")
        last_snapshot = "not found"
    
        while time.time() &lt; deadline:
            cr = _get_cr("maasauthpolicy", name, namespace)
            if cr is None:
                last_snapshot = "not found"
            else:
                status = cr.get("status", {})
                phase = status.get("phase")
                auth_policies = status.get("authPolicies", [])
                ready_count = sum(1 for ap in auth_policies if ap.get("ready") is True)
                last_snapshot = f"phase={phase}, authPolicies={len(auth_policies)} (ready={ready_count})"
    
                if phase == expected_phase:
                    # No per-model auth policies required — phase match is sufficient for the CR,
                    # but gateway-only mode still needs Kuadrant Enforced before HTTP calls.
                    # Callers that intentionally stop Kuadrant (e.g. TRLP degraded tests) must
                    # pass require_enforced=False — Enforced cannot become True while Kuadrant is down.
                    if not require_auth_policies:
                        if require_enforced and expected_phase == "Active":
                            # Keep a floor so a slow phase wait does not starve Kuadrant Enforced.
                            # AuthConfig backlog after policy churn often needs the full enforced timeout.
                            remaining = max(GATEWAY_ENFORCED_TIMEOUT, int(deadline - time.time()))
                            _wait_for_gateway_auth_enforced(timeout=remaining)
                        log.info(f"MaaSAuthPolicy {name} reached phase '{expected_phase}'")
                        return cr
    
                    # Auth policies required — check they exist
                    if len(auth_policies) &gt; 0:
                        if require_enforced:
                            all_enforced = all(
                                ap.get("ready") is True
                                for ap in auth_policies
                            )
                            if all_enforced:
                                log.info(f"MaaSAuthPolicy {name} reached phase '{expected_phase}' and all enforced")
                                return cr
                        else:
                            log.info(f"MaaSAuthPolicy {name} reached phase '{expected_phase}' with {len(auth_policies)} auth policy status(es)")
                            return cr
    
                log.debug(f"MaaSAuthPolicy {name}: {last_snapshot}")
            time.sleep(2)
    
        # Report what the loop last saw: a re-read after the deadline can show a
        # state the loop never evaluated.
&gt;       raise TimeoutError(
            f"MaaSAuthPolicy {name} did not reach phase '{expected_phase}' within {timeout}s "
            f"(last seen: {last_snapshot})"
        )
E       TimeoutError: MaaSAuthPolicy e2e-neg-ghost-policy-82f5834f did not reach phase 'Degraded' within 60s (last seen: phase=Pending, authPolicies=0 (ready=0))

test/e2e/tests/test_helper.py:1889: TimeoutError</failure></testcase><testcase classname="tests.test_models_endpoint.TestModelsEndpoint" name="test_service_account_token_multiple_subs_no_header" time="24.778" /><testcase classname="tests.test_negative_security.TestInternalEndpointIsolation" name="test_internal_endpoint_not_routable[subscriptions-select]" time="0.307" /><testcase classname="tests.test_negative_security.TestInternalEndpointIsolation" name="test_internal_endpoint_not_routable[api-keys-validate]" time="0.264" /><testcase classname="tests.test_negative_security.TestInternalEndpointIsolation" name="test_health_endpoint_accessible" time="0.036" /><testcase classname="tests.test_negative_security.TestInternalEndpointIsolation" name="test_v1_models_via_maas_api_prefix" time="0.289" /><testcase classname="tests.test_networkpolicy.TestPayloadProcessingNetworkPolicyExists" name="test_networkpolicy_exists" time="0.152" /><testcase classname="tests.test_networkpolicy.TestPayloadProcessingNetworkPolicyExists" name="test_pod_selector_covers_both_processors" time="0.157" /><testcase classname="tests.test_networkpolicy.TestPayloadProcessingNetworkPolicyExists" name="test_ingress_uses_istio_managed_label" time="0.155" /><testcase classname="tests.test_networkpolicy.TestPayloadProcessingNetworkPolicyExists" name="test_egress_allows_otlp_to_monitoring_namespace" time="0.298"><skipped type="pytest.skip" message="AIGC praxis NetworkPolicy does not include OTLP 4317 egress (MaaS Go IPP bundle only)">/workspace/source/test/e2e/tests/test_networkpolicy.py:119: AIGC praxis NetworkPolicy does not include OTLP 4317 egress (MaaS Go IPP bundle only)</skipped></testcase><testcase classname="tests.test_networkpolicy.TestPayloadProcessingNetworkPolicyExists" name="test_ingress_does_not_hardcode_single_gateway" time="0.163" /><testcase classname="tests.test_networkpolicy.TestMaaSAuthorinoNetworkPolicy" name="test_rhcl_authorino_namespace_is_allowed" time="0.153" /><testcase classname="tests.test_networkpolicy.TestPayloadProcessingConnectivity" name="test_maas_gateway_pod_exists" time="0.201" /><testcase classname="tests.test_networkpolicy.TestPayloadProcessingConnectivity" name="test_maas_gateway_has_istio_managed_label" time="0.195" /><testcase classname="tests.test_networkpolicy.TestPayloadProcessingConnectivity" name="test_payload_processing_pods_running" time="0.210" /><testcase classname="tests.test_networkpolicy.TestMaaSGatewayFunctional" name="test_maas_api_health" time="0.034" /><testcase classname="tests.test_networkpolicy.TestMaaSGatewayFunctional" name="test_maas_api_models_reachable" time="0.094" /><testcase classname="tests.test_multi_tenant_maas_api.TestPerTenantMaaSAPI" name="test_httproute_tenant_attachment" time="233.030" /><testcase classname="tests.test_negative_security.TestHeaderAbuse" name="test_special_characters_in_subscription_header" time="4.939" /><testcase classname="tests.test_multi_tenant_maas_api.TestPerTenantMaaSAPI" name="test_aitenant_creates_dedicated_maas_api_infrastructure" time="257.575" /><testcase classname="tests.test_namespace_scoping.TestMaaSAPIWatchNamespace" name="test_subscription_in_subscription_namespace_visible_to_api" time="0.000"><skipped type="pytest.skip" message="test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true">/workspace/source/test/e2e/tests/test_namespace_scoping.py:214: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="tests.test_multi_tenant_maas_api.TestPerTenantMaaSAPI" name="test_default_and_multiple_tenants_coexist" time="323.922" /><testcase classname="tests.test_negative_security.TestInternalEndpointIsolation" name="test_internal_endpoint_not_routable[api-keys-cleanup]" time="0.254" /><testcase classname="tests.test_multi_tenant_maas_api.TestPerTenantMaaSAPI" name="test_tenant_name_environment_variable_set" time="324.604" /><testcase classname="tests.test_per_tenant_ipp_isolation.TestPerTenantIPPInfrastructure" name="test_per_tenant_ipp_deployments_exist" time="260.546" /><testcase classname="tests.test_per_tenant_ipp_isolation.TestPerTenantIPPInfrastructure" name="test_per_tenant_ipp_env_vars" time="59.928"><skipped type="pytest.skip" message="praxis-extproc; Go IPP GATEWAY_NAME/TENANT_NAMESPACE env not applicable">/workspace/source/test/e2e/tests/test_per_tenant_ipp_isolation.py:231: praxis-extproc; Go IPP GATEWAY_NAME/TENANT_NAMESPACE env not applicable</skipped></testcase><testcase classname="tests.test_per_tenant_ipp_isolation.TestPerTenantIPPInfrastructure" name="test_per_tenant_envoyfilter_workload_selector_isolated" time="259.923" /><testcase classname="tests.test_per_tenant_ipp_isolation.TestPerTenantIPPInfrastructure" name="test_per_tenant_envoyfilter_grpc_clusters" time="64.588"><skipped type="pytest.skip" message="praxis-extproc; EnvoyFilter uses payload-*-extproc clusters (see test_per_tenant_praxis_isolation)">/workspace/source/test/e2e/tests/test_per_tenant_ipp_isolation.py:262: praxis-extproc; EnvoyFilter uses payload-*-extproc clusters (see test_per_tenant_praxis_isolation)</skipped></testcase><testcase classname="tests.test_per_tenant_ipp_isolation.TestPerTenantIPPInfrastructure" name="test_default_tenant_keeps_legacy_ipp_names" time="0.310" /><testcase classname="tests.test_per_tenant_ipp_isolation.TestPerTenantIPPInfrastructure" name="test_per_tenant_networkpolicy_when_applied" time="284.433" /><testcase classname="tests.test_per_tenant_ipp_isolation.TestPerTenantIPPRouting" name="test_default_gateway_hits_default_ipp_only" time="74.697" /><testcase classname="tests.test_multi_tenant_maas_api.TestPerTenantMaaSAPI" name="test_service_routing_isolation" time="332.003" /><testcase classname="tests.test_per_tenant_praxis_isolation.TestPerTenantPraxisInfrastructure" name="test_per_tenant_envoyfilter_workload_selector_isolated" time="177.471" /><testcase classname="tests.test_per_tenant_praxis_isolation.TestPerTenantPraxisInfrastructure" name="test_default_tenant_keeps_unsuffixed_payload_processing_names" time="75.096" /><testcase classname="tests.test_per_tenant_praxis_isolation.TestPerTenantPraxisInfrastructure" name="test_per_tenant_envoyfilter_grpc_clusters" time="184.331" /><testcase classname="tests.test_per_tenant_praxis_isolation.TestPerTenantPraxisInfrastructure" name="test_multiple_tenant_praxis_stacks_coexist" time="71.802" /><testcase classname="tests.test_per_tenant_praxis_isolation.TestPerTenantPraxisInfrastructure" name="test_per_tenant_networkpolicy_when_applied" time="182.101" /><testcase classname="tests.test_per_tenant_praxis_isolation.TestPerTenantPraxisRouting" name="test_default_gateway_hits_default_praxis_only" time="66.332" /><testcase classname="tests.test_smoke" name="test_tokens_endpoint_replaced_by_api_keys" time="0.064" /><testcase classname="tests.test_smoke" name="test_chat_completions_streaming_sse" time="0.452" /><testcase classname="tests.test_smoke" name="test_legacy_completions_optionally" time="0.101" /><testcase classname="tests.test_subscription.TestAuthEnforcement" name="test_authorized_user_gets_200" time="0.364" /><testcase classname="tests.test_subscription.TestAuthEnforcement" name="test_no_auth_gets_401" time="0.045" /><testcase classname="tests.test_subscription.TestAuthEnforcement" name="test_invalid_token_gets_403" time="0.108" /><testcase classname="tests.test_subscription.TestAuthEnforcement" name="test_wrong_group_gets_403" time="0.059" /><testcase classname="tests.test_subscription.TestAPIKeySubscriptionBinding" name="test_create_api_key_uses_highest_priority_subscription" time="2.885" /><testcase classname="tests.test_subscription.TestAPIKeySubscriptionBinding" name="test_create_api_key_with_explicit_simulator_subscription" time="0.201" /><testcase classname="tests.test_subscription.TestAPIKeySubscriptionBinding" name="test_create_api_key_nonexistent_subscription_errors" time="10.489" /><testcase classname="tests.test_subscription.TestSubscriptionEnforcement" name="test_subscribed_user_gets_200" time="0.373" /><testcase classname="tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_with_both_access_and_subscription_gets_200" time="97.768" /><testcase classname="tests.test_smoke" name="test_models_catalog" time="0.125" /><testcase classname="tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_multiple_subscriptions_separate_keys_gets_200" time="95.549" /><testcase classname="tests.test_smoke" name="test_chat_completions_gateway_alive" time="0.401" /><testcase classname="tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_group_based_access_gets_200" time="83.317" /><testcase classname="tests.test_per_tenant_ipp_isolation.TestPerTenantIPPRouting" name="test_tenant_gateway_hits_tenant_ipp_only" time="405.035" /><testcase classname="tests.test_per_tenant_praxis_isolation.TestPerTenantPraxisCleanup" name="test_praxis_resources_removed_on_aitenant_delete" time="221.011" /><testcase classname="tests.test_per_tenant_ipp_isolation.TestPerTenantIPPCleanup" name="test_ipp_resources_removed_on_aitenant_delete" time="165.463" /><testcase classname="tests.test_per_tenant_ipp_isolation.TestPerTenantIPPInfrastructure" name="test_multiple_tenant_ipp_stacks_coexist" time="344.024" /><testcase classname="tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_group_based_subscription_but_no_auth_gets_403" time="14.745" /><testcase classname="tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_with_subscription_but_no_access_gets_403" time="15.319" /><testcase classname="tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_mint_api_key_denied_for_inaccessible_subscription" time="25.046" /><testcase classname="tests.test_subscription.TestStatusReporting" name="test_subscription_failed_status_with_missing_model" time="19.191" /><testcase classname="tests.test_subscription.TestStatusReporting" name="test_authpolicy_active_status_with_valid_model" time="8.207" /><testcase classname="tests.test_subscription.TestStatusReporting" name="test_authpolicy_degraded_status_with_partial_models" time="3.558" /><testcase classname="tests.test_subscription.TestStatusReporting" name="test_subscription_status_transitions_on_model_deletion" time="64.993" /><testcase classname="tests.test_smoke" name="test_healthz_or_404" time="0.291" /><testcase classname="tests.test_subscription.TestDegradedSubscriptionFiltering" name="test_models_endpoint_with_degraded_subscription_api_key" time="15.110" /><testcase classname="tests.test_subscription.TestStatusReporting" name="test_subscription_degraded_status_with_partial_models" time="14.829" /><testcase classname="tests.test_subscription.TestStatusReporting" name="test_authpolicy_failed_status_with_missing_model" time="13.509" /><testcase classname="tests.test_subscription.TestDegradedSubscriptionFiltering" name="test_models_endpoint_with_degraded_subscription_kube_token" time="14.349" /><testcase classname="tests.test_per_tenant_praxis_isolation.TestPerTenantPraxisInfrastructure" name="test_per_tenant_praxis_deployments_exist" time="233.156" /><testcase classname="tests.test_subscription_list_endpoints.TestListSubscriptions" name="test_returns_accessible_subscriptions" time="5.598" /><testcase classname="tests.test_subscription_list_endpoints.TestListSubscriptions" name="test_unauthenticated_returns_401[all-subscriptions]" time="4.404" /><testcase classname="tests.test_subscription_list_endpoints.TestListSubscriptions" name="test_model_ref_display_name_and_description_enriched" time="13.055" /><testcase classname="tests.test_subscription_list_endpoints.TestListSubscriptions" name="test_subscription_includes_model_refs" time="11.563" /><testcase classname="tests.test_subscription_list_endpoints.TestListSubscriptionsForModel" name="test_unknown_model_returns_empty" time="0.679" /><testcase classname="tests.test_tenant.TestTenantLifecycle" name="test_tenant_ready_and_phase_healthy" time="0.468" /><testcase classname="tests.test_subscription_list_endpoints.TestListSubscriptionsForModel" name="test_returns_subscriptions_for_model" time="25.996" /><testcase classname="tests.test_tenant.TestTenantContract" name="test_status_has_phase_and_conditions" time="0.153" /><testcase classname="tests.test_tenant.TestTenantContract" name="test_conditions_use_kubernetes_metav1_shape" time="0.161" /><testcase classname="tests.test_tenant.TestTenantNoFalseOwnership" name="test_maas_user_crs_not_owned_by_tenant" time="0.485" /><testcase classname="tests.test_subscription_list_endpoints.TestListSubscriptions" name="test_unauthenticated_returns_401[subscriptions-for-model]" time="4.981" /><testcase classname="tests.test_subscription_list_endpoints.TestSubscriptionModelAccessFiltering" name="test_omits_subscription_with_no_authorized_models" time="14.565" /><testcase classname="tests.test_subscription.TestDegradedSubscriptionFiltering" name="test_degraded_healthy_model_allows_inference" time="14.374" /><testcase classname="tests.test_tenant.TestTenantContract" name="test_spec_is_well_formed" time="0.447" /><testcase classname="tests.test_subscription.TestOrderingEdgeCases" name="test_subscription_before_auth_policy" time="17.702" /><testcase classname="tests.test_subscription.TestStatusReporting" name="test_subscription_active_status_with_valid_model" time="28.025" /><testcase classname="tests.test_tenant_auto_resolve.TestTenantAutoResolve" name="test_explicit_tenant_ref_preserved" time="174.859" /><testcase classname="tests.test_tenant_auto_resolve.TestTenantAutoResolve" name="test_no_matching_tenant_enters_failed" time="63.632" /><testcase classname="tests.test_tenant_discovery" name="test_tenant_discovery_with_invalid_token" time="3.238" /><testcase classname="tests.test_tenant_discovery" name="test_tenant_discovery_authenticated" time="0.001"><skipped type="pytest.skip" message="Skipping when Gateway uses ClusterIP + OpenShift Route (unsupported configuration). This mixes incompatible routing paradigms. Gateway has no external hostname in spec.listeners, so /v1/tenants returns an error. Supported configuration: LoadBalancer service with hostname in spec.listeners.">/workspace/source/test/e2e/tests/test_tenant_discovery.py:79: Skipping when Gateway uses ClusterIP + OpenShift Route (unsupported configuration). This mixes incompatible routing paradigms. Gateway has no external hostname in spec.listeners, so /v1/tenants returns an error. Supported configuration: LoadBalancer service with hostname in spec.listeners.</skipped></testcase><testcase classname="tests.test_tenant_discovery" name="test_tenant_discovery_gateway_matches_deployment" time="0.001"><skipped type="pytest.skip" message="Skipping when Gateway uses ClusterIP + OpenShift Route (unsupported configuration). This mixes incompatible routing paradigms. Gateway has no external hostname in spec.listeners, so /v1/tenants returns an error. Supported configuration: LoadBalancer service with hostname in spec.listeners.">/workspace/source/test/e2e/tests/test_tenant_discovery.py:155: Skipping when Gateway uses ClusterIP + OpenShift Route (unsupported configuration). This mixes incompatible routing paradigms. Gateway has no external hostname in spec.listeners, so /v1/tenants returns an error. Supported configuration: LoadBalancer service with hostname in spec.listeners.</skipped></testcase><testcase classname="tests.test_tenant_discovery" name="test_tenant_discovery_not_exposed_through_gateway" time="0.051" /><testcase classname="tests.test_tenant_discovery" name="test_tenant_discovery_requires_auth" time="5.033" /><testcase classname="tests.test_tenant_discovery_isolation" name="test_tenant_discovery_same_tenant_access" time="169.207"><skipped type="pytest.skip" message="Skipping when Gateway uses ClusterIP + OpenShift Route (unsupported configuration). This mixes incompatible routing paradigms. Gateway has no external hostname in spec.listeners, so /v1/tenants returns an error. Supported configuration: LoadBalancer service with hostname in spec.listeners.">/workspace/source/test/e2e/tests/test_tenant_discovery_isolation.py:93: Skipping when Gateway uses ClusterIP + OpenShift Route (unsupported configuration). This mixes incompatible routing paradigms. Gateway has no external hostname in spec.listeners, so /v1/tenants returns an error. Supported configuration: LoadBalancer service with hostname in spec.listeners.</skipped></testcase><testcase classname="tests.test_tenant_discovery_isolation" name="test_tenant_discovery_cross_tenant_isolation" time="0.001"><skipped type="pytest.skip" message="Skipping when Gateway uses ClusterIP + OpenShift Route (unsupported configuration). This mixes incompatible routing paradigms. Gateway has no external hostname in spec.listeners, so /v1/tenants returns an error. Supported configuration: LoadBalancer service with hostname in spec.listeners.">/workspace/source/test/e2e/tests/test_tenant_discovery_isolation.py:141: Skipping when Gateway uses ClusterIP + OpenShift Route (unsupported configuration). This mixes incompatible routing paradigms. Gateway has no external hostname in spec.listeners, so /v1/tenants returns an error. Supported configuration: LoadBalancer service with hostname in spec.listeners.</skipped></testcase><testcase classname="tests.test_per_tenant_praxis_isolation.TestPerTenantPraxisRouting" name="test_tenant_gateway_hits_tenant_praxis_only" time="568.154" /><testcase classname="tests.test_tenant_discovery_isolation" name="test_tenant_discovery_unauthorized_access" time="193.138" /><testcase classname="tests.test_tenant_discovery_isolation" name="test_tenant_discovery_each_tenant_returns_own_gateway" time="0.001"><skipped type="pytest.skip" message="Skipping when Gateway uses ClusterIP + OpenShift Route (unsupported configuration). This mixes incompatible routing paradigms. Gateway has no external hostname in spec.listeners, so /v1/tenants returns an error. Supported configuration: LoadBalancer service with hostname in spec.listeners.">/workspace/source/test/e2e/tests/test_tenant_discovery_isolation.py:228: Skipping when Gateway uses ClusterIP + OpenShift Route (unsupported configuration). This mixes incompatible routing paradigms. Gateway has no external hostname in spec.listeners, so /v1/tenants returns an error. Supported configuration: LoadBalancer service with hostname in spec.listeners.</skipped></testcase><testcase classname="tests.test_subscription_list_endpoints.TestSubscriptionModelAccessFiltering" name="test_filters_unauthorized_models" time="19.365" /><testcase classname="tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_creation_scoped_to_tenant" time="583.886" /><testcase classname="tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_rejected_cross_tenant" time="26.285" /><testcase classname="tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_list_scoped_to_tenant" time="578.230" /><testcase classname="tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_validates_against_correct_tenant" time="570.249" /><testcase classname="tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_oidc_token_validation_per_tenant" time="44.027"><skipped type="pytest.skip" message="Per-tenant OIDC tokens unavailable — set OIDC_TOKEN_URL (tenant-a) and OIDC_TOKEN_URL_TENANT_B (tenant-b), or OIDC_TOKEN_TENANT_A / OIDC_TOKEN_TENANT_B">/workspace/source/test/e2e/tests/test_tenant_auth_isolation.py:223: Per-tenant OIDC tokens unavailable — set OIDC_TOKEN_URL (tenant-a) and OIDC_TOKEN_URL_TENANT_B (tenant-b), or OIDC_TOKEN_TENANT_A / OIDC_TOKEN_TENANT_B</skipped></testcase><testcase classname="tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_metadata_not_leaked_cross_tenant" time="560.133" /><testcase classname="tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_subscription_selection_uses_tenant_namespace" time="37.077" /><testcase classname="tests.test_tenant_auto_resolve.TestTenantAutoResolve" name="test_auto_resolve_populates_resolved_tenant_ref" time="186.742" /><testcase classname="tests.test_tenant_external_model_attachment.TestUserNamespaceAttachmentServing" name="test_attachment_status_ready" time="367.399" /><testcase classname="tests.test_tenant_external_model_attachment.TestUserNamespaceAttachmentServing" name="test_one_httproute_in_model_namespace" time="25.034" /><testcase classname="tests.test_tenant_external_model_conflicts.TestModelNameConflict" name="test_oldest_wins_when_no_tenant_own_model" time="141.444" /><testcase classname="tests.test_tenant_external_model_attachment.TestUserNamespaceAttachmentServing" name="test_credential_copy_delivered_to_tenant" time="352.770" /><testcase classname="tests.test_tenant_external_model_attachment.TestUserNamespaceAttachmentServing" name="test_unselected_gateway_not_serving" time="25.629" /><testcase classname="tests.test_tenant_external_model_crossns.TestCrossNsProviderGrant" name="test_grant_permits_cross_namespace_provider" time="0.000"><skipped type="pytest.skip" message="cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable">/workspace/source/test/e2e/tests/test_tenant_external_model_crossns.py:199: cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable</skipped></testcase><testcase classname="tests.test_tenant_external_model_crossns.TestMissingGrant" name="test_missing_grant_rejects_then_restores" time="0.000"><skipped type="pytest.skip" message="cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable">/workspace/source/test/e2e/tests/test_tenant_external_model_crossns.py:227: cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable</skipped></testcase><testcase classname="tests.test_tenant_external_model_crossns.TestMissingGrant" name="test_non_matching_grant_rejects" time="0.000"><skipped type="pytest.skip" message="cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable">/workspace/source/test/e2e/tests/test_tenant_external_model_crossns.py:251: cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable</skipped></testcase><testcase classname="tests.test_tenant_external_model_crossns.TestGrantRevocation" name="test_revoke_stops_access" time="0.000"><skipped type="pytest.skip" message="cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable">/workspace/source/test/e2e/tests/test_tenant_external_model_crossns.py:268: cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable</skipped></testcase><testcase classname="tests.test_tenant_external_model_crossns.TestGrantRevocation" name="test_narrowed_grant_stops_access" time="0.000"><skipped type="pytest.skip" message="cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable">/workspace/source/test/e2e/tests/test_tenant_external_model_crossns.py:307: cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable</skipped></testcase><testcase classname="tests.test_tenant_external_model_crossns.TestCredentialSourceSelection" name="test_provider_local_credential_used_by_default" time="0.000"><skipped type="pytest.skip" message="cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable">/workspace/source/test/e2e/tests/test_tenant_external_model_crossns.py:341: cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable</skipped></testcase><testcase classname="tests.test_tenant_external_model_crossns.TestCredentialSourceSelection" name="test_missing_model_local_override_fails_without_fallback" time="0.000"><skipped type="pytest.skip" message="cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable">/workspace/source/test/e2e/tests/test_tenant_external_model_crossns.py:396: cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable</skipped></testcase><testcase classname="tests.test_tenant_external_model_crossns.TestSameNamedProvidersTwoNamespaces" name="test_same_named_providers_both_serve" time="0.000"><skipped type="pytest.skip" message="cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable">/workspace/source/test/e2e/tests/test_tenant_external_model_crossns.py:434: cross-namespace provider E2E is gated until AGC ships cross-namespace provider support; set TENANT_EXTERNAL_MODEL_CROSSNS_E2E=true to enable</skipped></testcase><testcase classname="tests.test_tenant_external_model_attachment.TestListenerNotAllowed" name="test_nothing_published_into_tenant" time="300.163" /><testcase classname="tests.test_tenant_external_model_attachment.TestListenerNotAllowed" name="test_attachment_reports_not_allowed_by_listeners" time="297.887" /><testcase classname="tests.test_tenant_external_model_default_tenant.TestDefaultTenantServesModelWithoutGatewayRefs" name="test_attached_to_default_gateway" time="92.445" /><testcase classname="tests.test_tenant_external_model_default_tenant.TestDefaultTenantServesModelWithoutGatewayRefs" name="test_provider_reports_ready" time="33.450" /><testcase classname="tests.test_tenant_external_model_conflicts.TestModelNameConflict" name="test_tenant_own_model_wins_over_older_user_namespace_model" time="173.934" /><testcase classname="tests.test_tenant_external_model_default_tenant.TestImplicitAttachmentLifecycle" name="test_gateway_refs_replace_implicit_attachment" time="10.771" /><testcase classname="tests.test_tenant_external_model_shared.TestSharedModelTwoGateways" name="test_one_httproute_per_attachment" time="7.690" /><testcase classname="tests.test_tenant_external_model_shared.TestSharedModelTwoGateways" name="test_per_gateway_status" time="0.626" /><testcase classname="tests.test_tenant_external_model_attachment.TestUserNamespaceAttachmentServing" name="test_inference_serves_with_user_namespace_credential" time="408.953" /><testcase classname="tests.test_tenant_external_model_attachment.TestAttachmentLifecycleCleanup" name="test_model_delete_removes_serving_config" time="442.297" /><testcase classname="tests.test_tenant_external_model_attachment.TestAttachmentLifecycleCleanup" name="test_detach_removes_only_that_attachment" time="270.618" /><testcase classname="tests.test_tenant_external_model_conflicts.TestSameNamedObjectsTwoNamespaces" name="test_same_named_objects_both_attach" time="227.032" /><testcase classname="tests.test_tenant_external_model_attachment.TestListenerNotAllowed" name="test_route_not_admitted_and_not_served" time="40.758" /><testcase classname="tests.test_tenant_external_model_compat.TestOmittedGatewayRefsUnchanged" name="test_adding_own_tenant_gateway_refs_recreates_nothing" time="165.261" /><testcase classname="tests.test_tenant_external_model_default_tenant.TestImplicitAttachmentLifecycle" name="test_model_delete_removes_implicit_attachment" time="10.904" /><testcase classname="tests.test_tenant_external_model_default_tenant.TestDefaultTenantServesModelWithoutGatewayRefs" name="test_unknown_key_rejected" time="73.970" /><testcase classname="tests.test_tenant_external_model_default_tenant.TestDefaultTenantServesModelWithoutGatewayRefs" name="test_served_through_default_gateway" time="117.737" /><testcase classname="tests.test_tenant_external_model_shared.TestSharedModelTwoGateways" name="test_both_gateways_serve" time="315.042"><skipped type="pytest.skip" message="client-facing model names are not resolvable through the gateway yet: MaaSModelRef e2e-extmod-shr-user-6bb225/e2e-shr-shared-384e87-e2e-extmod-a-e1769a status.resolvedModelAlias='e2e-shr-shared-384e87' != 'e2e-shr-shared-384e87-client'">/workspace/source/test/e2e/tests/test_tenant_external_model_shared.py:165: client-facing model names are not resolvable through the gateway yet: MaaSModelRef e2e-extmod-shr-user-6bb225/e2e-shr-shared-384e87-e2e-extmod-a-e1769a status.resolvedModelAlias='e2e-shr-shared-384e87' != 'e2e-shr-shared-384e87-client'</skipped></testcase><testcase classname="tests.test_tenant_external_model_compat.TestOmittedGatewayRefsUnchanged" name="test_omitted_gateway_refs_serve_via_tenant_local_resolution" time="503.846" /><testcase classname="tests.test_tenant_external_model_shared.TestTenantQuotaIsolation" name="test_quota_exhaustion_isolated_per_tenant" time="439.765"><skipped type="pytest.skip" message="client-facing model names are not resolvable through the gateway yet: MaaSModelRef e2e-extmod-shr-user-eba670/e2e-shr-quota-735a79-e2e-extmod-a-6f162a status.resolvedModelAlias='e2e-shr-quota-735a79' != 'e2e-shr-quota-735a79-client'">/workspace/source/test/e2e/tests/test_tenant_external_model_shared.py:165: client-facing model names are not resolvable through the gateway yet: MaaSModelRef e2e-extmod-shr-user-eba670/e2e-shr-quota-735a79-e2e-extmod-a-6f162a status.resolvedModelAlias='e2e-shr-quota-735a79' != 'e2e-shr-quota-735a79-client'</skipped></testcase><testcase classname="tests.test_tenant_external_model_conflicts.TestSameNamedObjectsTwoNamespaces" name="test_same_named_objects_both_serve" time="235.846"><skipped type="pytest.skip" message="client-facing model names are not resolvable through the gateway yet: MaaSModelRef e2e-extmod-cfl-2-2aa680/e2e-cfl-same-32cb67 status.resolvedModelAlias='e2e-cfl-same-32cb67' != 'e2e-cfl-same-32cb67-two'">/workspace/source/test/e2e/tests/test_tenant_external_model_conflicts.py:362: client-facing model names are not resolvable through the gateway yet: MaaSModelRef e2e-extmod-cfl-2-2aa680/e2e-cfl-same-32cb67 status.resolvedModelAlias='e2e-cfl-same-32cb67' != 'e2e-cfl-same-32cb67-two'</skipped></testcase><testcase classname="tests.test_tenant_external_model_shared.TestTenantAuthIsolation" name="test_tenant_keys_authorized_only_on_their_own_gateway" time="264.903"><skipped type="pytest.skip" message="client-facing model names are not resolvable through the gateway yet: MaaSModelRef e2e-extmod-shr-user-6bb225/e2e-shr-auth-833fef-e2e-extmod-a-e1769a status.resolvedModelAlias='e2e-shr-auth-833fef' != 'e2e-shr-auth-833fef-client'">/workspace/source/test/e2e/tests/test_tenant_external_model_shared.py:165: client-facing model names are not resolvable through the gateway yet: MaaSModelRef e2e-extmod-shr-user-6bb225/e2e-shr-auth-833fef-e2e-extmod-a-e1769a status.resolvedModelAlias='e2e-shr-auth-833fef' != 'e2e-shr-auth-833fef-client'</skipped></testcase><testcase classname="tests.test_tenant_external_model_shared.TestTenantAuthIsolation" name="test_unknown_key_rejected_on_both_gateways" time="371.453" /><testcase classname="tests.test_tenant_model_inference.TestTenantModelInference" name="test_auth_envoyfilters_select_their_gateway_workloads" time="710.765"><error message="failed on setup with &quot;AssertionError: maasauthpolicy/test-model-90f683-auth in ai-tenant-e2e-inf-a-90f683 did not satisfy condition. Last object: {'apiVersion': 'maas.opendatahub.io/v1alpha1', 'kind': 'MaaSAuthPolicy', 'metadata': {'annotations': {'kubectl.kubernetes.io/last-applied-configuration': '{&quot;apiVersion&quot;:&quot;maas.opendatahub.io/v1alpha1&quot;,&quot;kind&quot;:&quot;MaaSAuthPolicy&quot;,&quot;metadata&quot;:{&quot;annotations&quot;:{},&quot;name&quot;:&quot;test-model-90f683-auth&quot;,&quot;namespace&quot;:&quot;ai-tenant-e2e-inf-a-90f683&quot;},&quot;spec&quot;:{&quot;modelRefs&quot;:[{&quot;name...&#10;[truncated; full report in element text]">@pytest.fixture(scope="module")
    def tenant_inference_cases():
        """Set up two tenants with models for inference testing."""
        require_aitenant_crd()
        case_a = new_named_tenant_case("e2e-inf-a")
        case_b = new_named_tenant_case("e2e-inf-b")
    
        try:
            # Bootstrap tenants
            for case in (case_a, case_b):
                bootstrap_aitenant_tenant(case)
    
            # Create both LLMInferenceServices before waiting on either. The llmisvc
            # controller reconciles them one at a time and runs minutes behind under
            # parallel load, so B should queue while A's wait runs, not after it.
            for case in (case_a, case_b):
                # Track model name early for cleanup
                case["model_name"] = f"test-model-{case['suffix']}"
                _create_llmis(
                    case["model_name"],
                    case["tenant_ns"],
                    case["gateway_name"],
                    GATEWAY_NAMESPACE,
                )
    
            for case in (case_a, case_b):
                model_name = case["model_name"]
                # Re-applies the LLMIS created above unchanged, then waits for it.
                provision_tenant_model(
                    model_name,
                    case["tenant_ns"],
                    case["gateway_name"],
                    ready_timeout=MODEL_BACKEND_READY_TIMEOUT,
                )
&gt;               make_tenant_model_accessible(
                    model_name,
                    case["tenant_ns"],
                    f"{model_name}-auth",
                    f"{model_name}-sub",
                    token_limit=10000,
                    gateway_name=case["gateway_name"],
                )

test/e2e/tests/test_tenant_model_inference.py:177: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/e2e/tests/multitenancy_helpers.py:1242: in make_tenant_model_accessible
    wait_for_status_phase(
test/e2e/tests/multitenancy_helpers.py:324: in wait_for_status_phase
    return wait_for_json(kind, name, namespace, predicate=_predicate, timeout=timeout, interval=interval)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

kind = 'maasauthpolicy', name = 'test-model-90f683-auth'
namespace = 'ai-tenant-e2e-inf-a-90f683'
predicate = &lt;function wait_for_status_phase.&lt;locals&gt;._predicate at 0x7f54b6514ae0&gt;
timeout = 180, interval = 5

    def wait_for_json(
        kind: str,
        name: str,
        namespace: Optional[str] = None,
        *,
        predicate=None,
        timeout: int = 180,
        interval: int = 5,
    ) -&gt; dict:
        deadline = time.time() + timeout
        last_obj = None
        while time.time() &lt; deadline:
            obj = get_json_or_none(kind, name, namespace)
            if obj is not None:
                last_obj = obj
                if predicate is None or predicate(obj):
                    return obj
            time.sleep(interval)
&gt;       raise AssertionError(
            f"{kind}/{name} in {namespace or '&lt;cluster&gt;'} did not satisfy condition. Last object: {last_obj}"
        )
E       AssertionError: maasauthpolicy/test-model-90f683-auth in ai-tenant-e2e-inf-a-90f683 did not satisfy condition. Last object: {'apiVersion': 'maas.opendatahub.io/v1alpha1', 'kind': 'MaaSAuthPolicy', 'metadata': {'annotations': {'kubectl.kubernetes.io/last-applied-configuration': '{"apiVersion":"maas.opendatahub.io/v1alpha1","kind":"MaaSAuthPolicy","metadata":{"annotations":{},"name":"test-model-90f683-auth","namespace":"ai-tenant-e2e-inf-a-90f683"},"spec":{"modelRefs":[{"name":"test-model-90f683","namespace":"ai-tenant-e2e-inf-a-90f683"}],"subjects":{"groups":[{"name":"system:authenticated"}]}}}\n'}, 'creationTimestamp': '2026-10-29T23:36:17Z', 'finalizers': ['maas.opendatahub.io/authpolicy-cleanup'], 'generation': 1, 'name': 'test-model-90f683-auth', 'namespace': 'ai-tenant-e2e-inf-a-90f683', 'resourceVersion': '152507', 'uid': '3ba68066-4273-4bbb-8f50-7fa67c7737cb'}, 'spec': {'modelRefs': [{'name': 'test-model-90f683', 'namespace': 'ai-tenant-e2e-inf-a-90f683'}], 'subjects': {'groups': [{'name': 'system:authenticated'}]}}, 'status': {'conditions': [{'lastTransitionTime': '2026-10-29T23:36:17Z', 'message': 'Waiting for gateway AuthPolicy openshift-ingress/e2e-inf-a-90f683-maas-auth to be accepted and enforced: AuthPolicy waiting for the following components to sync: [AuthConfig (61ceb1cbbddc83dc49cabb63dfbe82ce57108c09488c38b284d3a9c12882a181) AuthConfig (e81da58c401266637bb649e74b4d74bbf7a2b4aa75d0277aa0ab96625f9712c5) AuthConfig (a58cb8bcc1268a079aacc0f127a19087d2995c585dca7e812c6eb668b76428f4) AuthConfig (af0b8a3821de4a24044cba30bb35af2b90fea05d98c5fc98b6710881a45c1476) AuthConfig (172db0cf2837c4747bc23ebf9d56e91fa3df7b6a251672bac83b084b19574005) AuthConfig (8a1b50732a941e5c62158e1e23136121dfafdcafd3444ccc3ca4f5e0760858af) AuthConfig (c4b690b8b4b7bf7270db0a65e96ca915e68fc2e2d80a7fb07375cc33ba6d3290) AuthConfig (ba81a60852c27ccea4253431d16113e65cafe7a82105eda300e687e527122821) AuthConfig (fb50009d4a08af8234509e50b4c769db82bdbbc0d1b4b901294581986412a2a9) AuthConfig (0f81c26485f281d94493156328df483f5df9ff06ff6da868edbf2960d4d29eb5) AuthConfig (ca21a2cc4a2fd8fd9b255e38a644a6e8b735637b43f4dbfbaedfd7c6479cace9) AuthConfig (3d47f76b9a50802ac2c4bf3cc0a600b5f48c41eb9c23e80abfb3588e3782b886) AuthConfig (136ed36efd1b1bc9dbd29e50fd2af5e6432c6458321b3f71c55c9e979ffbb08b) AuthConfig (52293d8507c6ff0e73f3090bd7f0454f93c59f369e141d4ae434aa972a17f0e6) AuthConfig (b347ceebed28c4a95806893c61720f9adaf84254fd57b7af2f4ac9d6f5b63cbc) AuthConfig (989e7bbab87c9c4ee60d599fb0e6830bba2352a499bca89f08be49446ae70b19) AuthConfig (b062bccdbb066072d44d982e027a6c6f9101f59853b2ffc15fb263e749f0ec3f) AuthConfig (c75c5c8e03269df63044da1d9479ecbebb5b36b3b86eae056c259d4e0758928e)]', 'observedGeneration': 1, 'reason': 'Unknown', 'status': 'Unknown', 'type': 'Ready'}], 'phase': 'Pending'}}

test/e2e/tests/multitenancy_helpers.py:269: AssertionError</error></testcase><testcase classname="tests.test_tenant_model_inference.TestTenantModelInference" name="test_tenant_isolation_cross_gateway_blocked" time="368.811"><error message="failed on setup with &quot;AssertionError: maasauthpolicy/test-model-90f683-auth in ai-tenant-e2e-inf-a-90f683 did not satisfy condition. Last object: {'apiVersion': 'maas.opendatahub.io/v1alpha1', 'kind': 'MaaSAuthPolicy', 'metadata': {'annotations': {'kubectl.kubernetes.io/last-applied-configuration': '{&quot;apiVersion&quot;:&quot;maas.opendatahub.io/v1alpha1&quot;,&quot;kind&quot;:&quot;MaaSAuthPolicy&quot;,&quot;metadata&quot;:{&quot;annotations&quot;:{},&quot;name&quot;:&quot;test-model-90f683-auth&quot;,&quot;namespace&quot;:&quot;ai-tenant-e2e-inf-a-90f683&quot;},&quot;spec&quot;:{&quot;modelRefs&quot;:[{&quot;name...&#10;[truncated; full report in element text]">@pytest.fixture(scope="module")
    def tenant_inference_cases():
        """Set up two tenants with models for inference testing."""
        require_aitenant_crd()
        case_a = new_named_tenant_case("e2e-inf-a")
        case_b = new_named_tenant_case("e2e-inf-b")
    
        try:
            # Bootstrap tenants
            for case in (case_a, case_b):
                bootstrap_aitenant_tenant(case)
    
            # Create both LLMInferenceServices before waiting on either. The llmisvc
            # controller reconciles them one at a time and runs minutes behind under
            # parallel load, so B should queue while A's wait runs, not after it.
            for case in (case_a, case_b):
                # Track model name early for cleanup
                case["model_name"] = f"test-model-{case['suffix']}"
                _create_llmis(
                    case["model_name"],
                    case["tenant_ns"],
                    case["gateway_name"],
                    GATEWAY_NAMESPACE,
                )
    
            for case in (case_a, case_b):
                model_name = case["model_name"]
                # Re-applies the LLMIS created above unchanged, then waits for it.
                provision_tenant_model(
                    model_name,
                    case["tenant_ns"],
                    case["gateway_name"],
                    ready_timeout=MODEL_BACKEND_READY_TIMEOUT,
                )
&gt;               make_tenant_model_accessible(
                    model_name,
                    case["tenant_ns"],
                    f"{model_name}-auth",
                    f"{model_name}-sub",
                    token_limit=10000,
                    gateway_name=case["gateway_name"],
                )

test/e2e/tests/test_tenant_model_inference.py:177: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/e2e/tests/multitenancy_helpers.py:1242: in make_tenant_model_accessible
    wait_for_status_phase(
test/e2e/tests/multitenancy_helpers.py:324: in wait_for_status_phase
    return wait_for_json(kind, name, namespace, predicate=_predicate, timeout=timeout, interval=interval)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

kind = 'maasauthpolicy', name = 'test-model-90f683-auth'
namespace = 'ai-tenant-e2e-inf-a-90f683'
predicate = &lt;function wait_for_status_phase.&lt;locals&gt;._predicate at 0x7f54b6514ae0&gt;
timeout = 180, interval = 5

    def wait_for_json(
        kind: str,
        name: str,
        namespace: Optional[str] = None,
        *,
        predicate=None,
        timeout: int = 180,
        interval: int = 5,
    ) -&gt; dict:
        deadline = time.time() + timeout
        last_obj = None
        while time.time() &lt; deadline:
            obj = get_json_or_none(kind, name, namespace)
            if obj is not None:
                last_obj = obj
                if predicate is None or predicate(obj):
                    return obj
            time.sleep(interval)
&gt;       raise AssertionError(
            f"{kind}/{name} in {namespace or '&lt;cluster&gt;'} did not satisfy condition. Last object: {last_obj}"
        )
E       AssertionError: maasauthpolicy/test-model-90f683-auth in ai-tenant-e2e-inf-a-90f683 did not satisfy condition. Last object: {'apiVersion': 'maas.opendatahub.io/v1alpha1', 'kind': 'MaaSAuthPolicy', 'metadata': {'annotations': {'kubectl.kubernetes.io/last-applied-configuration': '{"apiVersion":"maas.opendatahub.io/v1alpha1","kind":"MaaSAuthPolicy","metadata":{"annotations":{},"name":"test-model-90f683-auth","namespace":"ai-tenant-e2e-inf-a-90f683"},"spec":{"modelRefs":[{"name":"test-model-90f683","namespace":"ai-tenant-e2e-inf-a-90f683"}],"subjects":{"groups":[{"name":"system:authenticated"}]}}}\n'}, 'creationTimestamp': '2026-10-29T23:36:17Z', 'finalizers': ['maas.opendatahub.io/authpolicy-cleanup'], 'generation': 1, 'name': 'test-model-90f683-auth', 'namespace': 'ai-tenant-e2e-inf-a-90f683', 'resourceVersion': '152507', 'uid': '3ba68066-4273-4bbb-8f50-7fa67c7737cb'}, 'spec': {'modelRefs': [{'name': 'test-model-90f683', 'namespace': 'ai-tenant-e2e-inf-a-90f683'}], 'subjects': {'groups': [{'name': 'system:authenticated'}]}}, 'status': {'conditions': [{'lastTransitionTime': '2026-10-29T23:36:17Z', 'message': 'Waiting for gateway AuthPolicy openshift-ingress/e2e-inf-a-90f683-maas-auth to be accepted and enforced: AuthPolicy waiting for the following components to sync: [AuthConfig (61ceb1cbbddc83dc49cabb63dfbe82ce57108c09488c38b284d3a9c12882a181) AuthConfig (e81da58c401266637bb649e74b4d74bbf7a2b4aa75d0277aa0ab96625f9712c5) AuthConfig (a58cb8bcc1268a079aacc0f127a19087d2995c585dca7e812c6eb668b76428f4) AuthConfig (af0b8a3821de4a24044cba30bb35af2b90fea05d98c5fc98b6710881a45c1476) AuthConfig (172db0cf2837c4747bc23ebf9d56e91fa3df7b6a251672bac83b084b19574005) AuthConfig (8a1b50732a941e5c62158e1e23136121dfafdcafd3444ccc3ca4f5e0760858af) AuthConfig (c4b690b8b4b7bf7270db0a65e96ca915e68fc2e2d80a7fb07375cc33ba6d3290) AuthConfig (ba81a60852c27ccea4253431d16113e65cafe7a82105eda300e687e527122821) AuthConfig (fb50009d4a08af8234509e50b4c769db82bdbbc0d1b4b901294581986412a2a9) AuthConfig (0f81c26485f281d94493156328df483f5df9ff06ff6da868edbf2960d4d29eb5) AuthConfig (ca21a2cc4a2fd8fd9b255e38a644a6e8b735637b43f4dbfbaedfd7c6479cace9) AuthConfig (3d47f76b9a50802ac2c4bf3cc0a600b5f48c41eb9c23e80abfb3588e3782b886) AuthConfig (136ed36efd1b1bc9dbd29e50fd2af5e6432c6458321b3f71c55c9e979ffbb08b) AuthConfig (52293d8507c6ff0e73f3090bd7f0454f93c59f369e141d4ae434aa972a17f0e6) AuthConfig (b347ceebed28c4a95806893c61720f9adaf84254fd57b7af2f4ac9d6f5b63cbc) AuthConfig (989e7bbab87c9c4ee60d599fb0e6830bba2352a499bca89f08be49446ae70b19) AuthConfig (b062bccdbb066072d44d982e027a6c6f9101f59853b2ffc15fb263e749f0ec3f) AuthConfig (c75c5c8e03269df63044da1d9479ecbebb5b36b3b86eae056c259d4e0758928e)]', 'observedGeneration': 1, 'reason': 'Unknown', 'status': 'Unknown', 'type': 'Ready'}], 'phase': 'Pending'}}

test/e2e/tests/multitenancy_helpers.py:269: AssertionError</error></testcase><testcase classname="tests.test_tenant_model_inference.TestTenantModelInference" name="test_model_routes_through_tenant_gateway" time="712.039" /><testcase classname="tests.test_tenant_model_inference.TestTenantGatewayNegativeSecurity" name="test_missing_api_key_denied_on_tenant_gateway[tenant_a]" time="447.127" /><testcase classname="tests.test_tenant_model_inference.TestTenantModelInference" name="test_inference_succeeds_through_tenant_gateway[tenant_a]" time="735.643" /><testcase classname="tests.test_tenant_model_inference.TestTenantGatewayNegativeSecurity" name="test_missing_api_key_denied_on_tenant_gateway[tenant_b]" time="512.524" /><testcase classname="tests.test_tenant_model_inference.TestTenantModelInference" name="test_inference_succeeds_through_tenant_gateway[tenant_b]" time="499.635"><error message="failed on setup with &quot;AssertionError: aitenant/e2e-inf-b-55c3fc in ai-tenants did not satisfy condition. Last object: {'apiVersion': 'maas.opendatahub.io/v1alpha1', 'kind': 'AITenant', 'metadata': {'annotations': {'kubectl.kubernetes.io/last-applied-configuration': '{&quot;apiVersion&quot;:&quot;maas.opendatahub.io/v1alpha1&quot;,&quot;kind&quot;:&quot;AITenant&quot;,&quot;metadata&quot;:{&quot;annotations&quot;:{},&quot;name&quot;:&quot;e2e-inf-b-55c3fc&quot;,&quot;namespace&quot;:&quot;ai-tenants&quot;},&quot;spec&quot;:{&quot;gateway&quot;:{&quot;name&quot;:&quot;e2e-inf-b-55c3fc&quot;}}}\n'}, 'creationTimestamp': '2026-10-29T23:...&#10;[truncated; full report in element text]">@pytest.fixture(scope="module")
    def tenant_inference_cases():
        """Set up two tenants with models for inference testing."""
        require_aitenant_crd()
        case_a = new_named_tenant_case("e2e-inf-a")
        case_b = new_named_tenant_case("e2e-inf-b")
    
        try:
            # Bootstrap tenants
            for case in (case_a, case_b):
&gt;               bootstrap_aitenant_tenant(case)

test/e2e/tests/test_tenant_model_inference.py:153: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/e2e/tests/multitenancy_helpers.py:1074: in bootstrap_aitenant_tenant
    wait_for_json(AITENANT_KIND, case["tenant_label_name"], AITENANT_NAMESPACE, predicate=aitenant_ready)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

kind = 'aitenant', name = 'e2e-inf-b-55c3fc', namespace = 'ai-tenants'
predicate = &lt;function aitenant_ready at 0x7f1534853740&gt;, timeout = 180
interval = 5

    def wait_for_json(
        kind: str,
        name: str,
        namespace: Optional[str] = None,
        *,
        predicate=None,
        timeout: int = 180,
        interval: int = 5,
    ) -&gt; dict:
        deadline = time.time() + timeout
        last_obj = None
        while time.time() &lt; deadline:
            obj = get_json_or_none(kind, name, namespace)
            if obj is not None:
                last_obj = obj
                if predicate is None or predicate(obj):
                    return obj
            time.sleep(interval)
&gt;       raise AssertionError(
            f"{kind}/{name} in {namespace or '&lt;cluster&gt;'} did not satisfy condition. Last object: {last_obj}"
        )
E       AssertionError: aitenant/e2e-inf-b-55c3fc in ai-tenants did not satisfy condition. Last object: {'apiVersion': 'maas.opendatahub.io/v1alpha1', 'kind': 'AITenant', 'metadata': {'annotations': {'kubectl.kubernetes.io/last-applied-configuration': '{"apiVersion":"maas.opendatahub.io/v1alpha1","kind":"AITenant","metadata":{"annotations":{},"name":"e2e-inf-b-55c3fc","namespace":"ai-tenants"},"spec":{"gateway":{"name":"e2e-inf-b-55c3fc"}}}\n'}, 'creationTimestamp': '2026-10-29T23:40:14Z', 'finalizers': ['maas.opendatahub.io/aitenant-cleanup'], 'generation': 1, 'name': 'e2e-inf-b-55c3fc', 'namespace': 'ai-tenants', 'resourceVersion': '156222', 'uid': 'b6ab2f7b-5724-4059-b2c1-063a0ee3e5da'}, 'spec': {'gateway': {'name': 'e2e-inf-b-55c3fc'}}, 'status': {'conditions': [{'lastTransitionTime': '2026-10-29T23:40:15Z', 'message': 'waiting for MaasTenantConfig to report Ready', 'observedGeneration': 1, 'reason': 'TenantConfigNotReady', 'status': 'False', 'type': 'Ready'}], 'gatewayRef': {'name': 'e2e-inf-b-55c3fc', 'namespace': 'openshift-ingress'}, 'phase': 'Pending', 'tenantNamespace': 'ai-tenant-e2e-inf-b-55c3fc'}}

test/e2e/tests/multitenancy_helpers.py:269: AssertionError</error></testcase><testcase classname="tests.test_tenant_model_inference.TestTenantGatewayNegativeSecurity" name="test_forged_identity_headers_denied_on_tenant_gateway[tenant_b]" time="267.514"><error message="failed on setup with &quot;AssertionError: aitenant/e2e-inf-b-55c3fc in ai-tenants did not satisfy condition. Last object: {'apiVersion': 'maas.opendatahub.io/v1alpha1', 'kind': 'AITenant', 'metadata': {'annotations': {'kubectl.kubernetes.io/last-applied-configuration': '{&quot;apiVersion&quot;:&quot;maas.opendatahub.io/v1alpha1&quot;,&quot;kind&quot;:&quot;AITenant&quot;,&quot;metadata&quot;:{&quot;annotations&quot;:{},&quot;name&quot;:&quot;e2e-inf-b-55c3fc&quot;,&quot;namespace&quot;:&quot;ai-tenants&quot;},&quot;spec&quot;:{&quot;gateway&quot;:{&quot;name&quot;:&quot;e2e-inf-b-55c3fc&quot;}}}\n'}, 'creationTimestamp': '2026-10-29T23:...&#10;[truncated; full report in element text]">@pytest.fixture(scope="module")
    def tenant_inference_cases():
        """Set up two tenants with models for inference testing."""
        require_aitenant_crd()
        case_a = new_named_tenant_case("e2e-inf-a")
        case_b = new_named_tenant_case("e2e-inf-b")
    
        try:
            # Bootstrap tenants
            for case in (case_a, case_b):
&gt;               bootstrap_aitenant_tenant(case)

test/e2e/tests/test_tenant_model_inference.py:153: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/e2e/tests/multitenancy_helpers.py:1074: in bootstrap_aitenant_tenant
    wait_for_json(AITENANT_KIND, case["tenant_label_name"], AITENANT_NAMESPACE, predicate=aitenant_ready)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

kind = 'aitenant', name = 'e2e-inf-b-55c3fc', namespace = 'ai-tenants'
predicate = &lt;function aitenant_ready at 0x7f1534853740&gt;, timeout = 180
interval = 5

    def wait_for_json(
        kind: str,
        name: str,
        namespace: Optional[str] = None,
        *,
        predicate=None,
        timeout: int = 180,
        interval: int = 5,
    ) -&gt; dict:
        deadline = time.time() + timeout
        last_obj = None
        while time.time() &lt; deadline:
            obj = get_json_or_none(kind, name, namespace)
            if obj is not None:
                last_obj = obj
                if predicate is None or predicate(obj):
                    return obj
            time.sleep(interval)
&gt;       raise AssertionError(
            f"{kind}/{name} in {namespace or '&lt;cluster&gt;'} did not satisfy condition. Last object: {last_obj}"
        )
E       AssertionError: aitenant/e2e-inf-b-55c3fc in ai-tenants did not satisfy condition. Last object: {'apiVersion': 'maas.opendatahub.io/v1alpha1', 'kind': 'AITenant', 'metadata': {'annotations': {'kubectl.kubernetes.io/last-applied-configuration': '{"apiVersion":"maas.opendatahub.io/v1alpha1","kind":"AITenant","metadata":{"annotations":{},"name":"e2e-inf-b-55c3fc","namespace":"ai-tenants"},"spec":{"gateway":{"name":"e2e-inf-b-55c3fc"}}}\n'}, 'creationTimestamp': '2026-10-29T23:40:14Z', 'finalizers': ['maas.opendatahub.io/aitenant-cleanup'], 'generation': 1, 'name': 'e2e-inf-b-55c3fc', 'namespace': 'ai-tenants', 'resourceVersion': '156222', 'uid': 'b6ab2f7b-5724-4059-b2c1-063a0ee3e5da'}, 'spec': {'gateway': {'name': 'e2e-inf-b-55c3fc'}}, 'status': {'conditions': [{'lastTransitionTime': '2026-10-29T23:40:15Z', 'message': 'waiting for MaasTenantConfig to report Ready', 'observedGeneration': 1, 'reason': 'TenantConfigNotReady', 'status': 'False', 'type': 'Ready'}], 'gatewayRef': {'name': 'e2e-inf-b-55c3fc', 'namespace': 'openshift-ingress'}, 'phase': 'Pending', 'tenantNamespace': 'ai-tenant-e2e-inf-b-55c3fc'}}

test/e2e/tests/multitenancy_helpers.py:269: AssertionError</error></testcase><testcase classname="tests.test_tenant_model_inference.TestTenantGatewayNegativeSecurity" name="test_invalid_api_key_denied_on_tenant_gateway[tenant_b]" time="710.473" /><testcase classname="tests.test_tenant_model_inference.TestTenantBodyRouting" name="test_model_in_body_routing[wrong-model]" time="294.282" /><testcase classname="tests.test_tenant_model_inference.TestTenantGatewayNegativeSecurity" name="test_forged_identity_headers_denied_on_tenant_gateway[tenant_a]" time="773.459" /><testcase classname="tests.test_tenant_model_inference.TestTenantBodyRouting" name="test_model_in_body_routing[correct-model]" time="296.265" /><testcase classname="tests.test_tenant_model_inference.TestTenantGatewayNegativeSecurity" name="test_invalid_api_key_denied_on_tenant_gateway[tenant_a]" time="719.088" /><testcase classname="tests.test_tenant_model_inference.TestTenantBodyRouting" name="test_model_in_body_routing[missing-model]" time="231.538" /></testsuite></testsuites>