<?xml version="1.0" encoding="utf-8"?><testsuites name="pytest tests"><testsuite name="pytest" errors="1" failures="4" skipped="11" tests="183" time="3949.829" timestamp="2026-07-29T20:37:44.310414+00:00" hostname="maas-group-test-v6plq-e2e-maas-openshift-pod"><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyCRUD" name="test_create_api_key" time="0.215" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyCRUD" name="test_list_api_keys" time="0.124" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyCRUD" name="test_revoke_api_key" time="0.116" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyAuthorization" name="test_admin_manage_other_users_keys" time="0.123" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyAuthorization" name="test_non_admin_cannot_access_other_users_keys" time="0.087" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_own_keys" time="0.252" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_other_user_forbidden" time="0.028" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyBulkOperations" name="test_bulk_revoke_admin_can_revoke_any_user" time="0.089" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyExpiration" name="test_create_key_within_expiration_limit" time="0.030" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyExpiration" name="test_create_key_at_expiration_limit" time="0.028" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyExpiration" name="test_create_key_exceeds_expiration_limit" time="0.032" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyExpiration" name="test_create_key_without_expiration" time="0.028" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyExpiration" name="test_create_key_with_short_expiration" time="0.030" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyModelInference" name="test_api_key_model_access_success" time="0.089" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyModelInference" name="test_invalid_api_key_rejected" time="0.025" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyModelInference" name="test_no_auth_header_rejected" time="0.020" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyModelInference" name="test_revoked_api_key_rejected" time="2.123" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyModelInference" name="test_api_key_chat_completions" time="0.034" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyRevocationE2E" name="test_double_revoke_returns_404" time="0.093" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyRevocationE2E" name="test_revoke_nonexistent_key_returns_404" time="0.031" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyRevocationE2E" name="test_revoke_then_create_new_key_works" time="0.144" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyRevocationE2E" name="test_individual_revoke_multiple_keys" time="0.211" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeyRevocationE2E" name="test_revoke_keys_rejected_at_gateway" time="0.270" /><testcase classname="test.e2e.tests.test_api_keys.TestEphemeralKeyCleanup" name="test_cronjob_exists_and_configured" time="0.111" /><testcase classname="test.e2e.tests.test_api_keys.TestEphemeralKeyCleanup" name="test_cleanup_networkpolicy_exists" time="0.115" /><testcase classname="test.e2e.tests.test_api_keys.TestEphemeralKeyCleanup" name="test_create_ephemeral_key" time="0.094" /><testcase classname="test.e2e.tests.test_api_keys.TestEphemeralKeyCleanup" name="test_trigger_cleanup_preserves_active_keys" time="0.518" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeySubscriptionPhases" name="test_create_key_for_active_subscription" time="7.522" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeySubscriptionPhases" name="test_create_key_for_degraded_subscription" time="15.183" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeySubscriptionPhases" name="test_create_key_for_failed_subscription" time="5.315" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeySubscriptionPhases" name="test_create_key_for_pending_subscription" time="78.910" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeySubscriptionPhases" name="test_reject_key_for_unreconciled_subscription" time="18.454" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeySubscriptionFilter" name="test_search_filters_by_subscription" time="6.533" /><testcase classname="test.e2e.tests.test_api_keys.TestAPIKeySubscriptionFilter" name="test_search_without_subscription_returns_all" time="0.294" /><testcase classname="test.e2e.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:212: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="test.e2e.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:245: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="test.e2e.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:283: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="test.e2e.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:320: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="test.e2e.tests.test_namespace_scoping.TestModelRef" name="test_auth_policy_model_ref" time="0.001"><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:377: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="test.e2e.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:453: test_namespace_scoping validates single-tenant dormant mode; skipped when ENABLE_TENANT_NAMESPACE_DISCOVERY=true</skipped></testcase><testcase classname="test.e2e.tests.test_negative_security.TestHeaderSpoofing" name="test_injected_identity_headers_ignored" time="0.211" /><testcase classname="test.e2e.tests.test_negative_security.TestHeaderSpoofing" name="test_duplicate_subscription_headers_ignored" time="0.176" /><testcase classname="test.e2e.tests.test_negative_security.TestExpiredKeyRejection" name="test_expired_key_rejected_at_gateway" time="5.072" /><testcase classname="test.e2e.tests.test_negative_security.TestCrossModelAccess" name="test_key_cannot_access_model_outside_subscription" time="0.194" /><testcase classname="test.e2e.tests.test_negative_security.TestAuthPolicyRemoval" name="test_authpolicy_deletion_revokes_access" time="11.466" /><testcase classname="test.e2e.tests.test_negative_security.TestMissingModelRef" name="test_subscription_with_nonexistent_model_ref" time="1.022" /><testcase classname="test.e2e.tests.test_negative_security.TestMissingModelRef" name="test_authpolicy_with_nonexistent_model_ref" time="11.243" /><testcase classname="test.e2e.tests.test_negative_security.TestHeaderAbuse" name="test_special_characters_in_subscription_header" time="0.260" /><testcase classname="test.e2e.tests.test_negative_security.TestWebhookValidation" name="test_subscription_rejected_in_unlabeled_namespace" time="6.207" /><testcase classname="test.e2e.tests.test_negative_security.TestWebhookValidation" name="test_authpolicy_rejected_in_unlabeled_namespace" time="5.974" /><testcase classname="test.e2e.tests.test_subscription.TestAuthEnforcement" name="test_authorized_user_gets_200" time="0.072" /><testcase classname="test.e2e.tests.test_subscription.TestAuthEnforcement" name="test_no_auth_gets_401" time="0.021" /><testcase classname="test.e2e.tests.test_subscription.TestAuthEnforcement" name="test_invalid_token_gets_403" time="0.040" /><testcase classname="test.e2e.tests.test_subscription.TestAuthEnforcement" name="test_wrong_group_gets_403" time="0.026" /><testcase classname="test.e2e.tests.test_subscription.TestAPIKeySubscriptionBinding" name="test_create_api_key_uses_highest_priority_subscription" time="0.315" /><testcase classname="test.e2e.tests.test_subscription.TestAPIKeySubscriptionBinding" name="test_create_api_key_with_explicit_simulator_subscription" time="0.060" /><testcase classname="test.e2e.tests.test_subscription.TestAPIKeySubscriptionBinding" name="test_create_api_key_nonexistent_subscription_errors" time="0.241" /><testcase classname="test.e2e.tests.test_subscription.TestSubscriptionEnforcement" name="test_subscribed_user_gets_200" time="0.033" /><testcase classname="test.e2e.tests.test_subscription.TestSubscriptionEnforcement" name="test_auth_pass_no_subscription_gets_403" time="8.405" /><testcase classname="test.e2e.tests.test_subscription.TestSubscriptionEnforcement" name="test_rate_limit_exhaustion_gets_429" time="19.803" /><testcase classname="test.e2e.tests.test_subscription.TestSubscriptionEnforcement" name="test_models_endpoint_exempt_from_rate_limiting" time="33.852" /><testcase classname="test.e2e.tests.test_subscription.TestMultipleSubscriptionsPerModel" name="test_user_in_one_of_two_subscriptions_gets_200" time="4.382" /><testcase classname="test.e2e.tests.test_subscription.TestMultipleAuthPoliciesPerModel" name="test_two_auth_policies_or_logic" time="8.755" /><testcase classname="test.e2e.tests.test_subscription.TestMultipleAuthPoliciesPerModel" name="test_delete_one_auth_policy_other_still_works" time="12.500" /><testcase classname="test.e2e.tests.test_subscription.TestCascadeDeletion" name="test_delete_subscription_rebuilds_trlp" time="4.511" /><testcase classname="test.e2e.tests.test_subscription.TestCascadeDeletion" name="test_trlp_persists_during_multi_subscription_deletion" time="17.319" /><testcase classname="test.e2e.tests.test_subscription.TestCascadeDeletion" name="test_delete_last_subscription_denies_access" time="4.616" /><testcase classname="test.e2e.tests.test_subscription.TestCascadeDeletion" name="test_unconfigured_model_denied_by_gateway_auth" time="0.511" /><testcase classname="test.e2e.tests.test_subscription.TestOrderingEdgeCases" name="test_subscription_before_auth_policy" time="20.255" /><testcase classname="test.e2e.tests.test_subscription.TestManagedAnnotation" name="test_authpolicy_managed_false_prevents_update" time="4.220"><skipped type="pytest.skip" message="gateway-only mode: per-model AuthPolicy is not created">/workspace/source/test/e2e/tests/test_subscription.py:1055: gateway-only mode: per-model AuthPolicy is not created</skipped></testcase><testcase classname="test.e2e.tests.test_subscription.TestManagedAnnotation" name="test_trlp_managed_false_prevents_update" time="12.650" /><testcase classname="test.e2e.tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_with_both_access_and_subscription_gets_200" time="16.361" /><testcase classname="test.e2e.tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_with_access_but_no_subscription_gets_403" time="9.265" /><testcase classname="test.e2e.tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_with_subscription_but_no_access_gets_403" time="16.296" /><testcase classname="test.e2e.tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_single_subscription_auto_selects" time="11.601" /><testcase classname="test.e2e.tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_multiple_subscriptions_separate_keys_gets_200" time="9.532" /><testcase classname="test.e2e.tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_mint_api_key_denied_for_inaccessible_subscription" time="9.732" /><testcase classname="test.e2e.tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_group_based_access_gets_200" time="9.105" /><testcase classname="test.e2e.tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_group_based_auth_but_no_subscription_gets_403" time="9.223" /><testcase classname="test.e2e.tests.test_subscription.TestE2ESubscriptionFlow" name="test_e2e_group_based_subscription_but_no_auth_gets_403" time="15.935" /><testcase classname="test.e2e.tests.test_subscription.TestStatusReporting" name="test_subscription_active_status_with_valid_model" time="15.909" /><testcase classname="test.e2e.tests.test_subscription.TestStatusReporting" name="test_subscription_failed_status_with_missing_model" time="4.792" /><testcase classname="test.e2e.tests.test_subscription.TestStatusReporting" name="test_authpolicy_active_status_with_valid_model" time="15.486" /><testcase classname="test.e2e.tests.test_subscription.TestStatusReporting" name="test_authpolicy_failed_status_with_missing_model" time="15.371" /><testcase classname="test.e2e.tests.test_subscription.TestStatusReporting" name="test_subscription_degraded_status_with_partial_models" time="5.162" /><testcase classname="test.e2e.tests.test_subscription.TestStatusReporting" name="test_subscription_degraded_trlp_blocks_inference" time="100.434" /><testcase classname="test.e2e.tests.test_subscription.TestStatusReporting" name="test_authpolicy_degraded_status_with_partial_models" time="15.422" /><testcase classname="test.e2e.tests.test_subscription.TestStatusReporting" name="test_subscription_status_transitions_on_model_deletion" time="31.302" /><testcase classname="test.e2e.tests.test_subscription.TestDegradedSubscriptionFiltering" name="test_degraded_healthy_model_allows_inference" time="15.251" /><testcase classname="test.e2e.tests.test_subscription.TestDegradedSubscriptionFiltering" name="test_failed_subscription_blocks_inference" time="15.521" /><testcase classname="test.e2e.tests.test_subscription.TestDegradedSubscriptionFiltering" name="test_models_endpoint_with_degraded_subscription_api_key" time="15.244" /><testcase classname="test.e2e.tests.test_subscription.TestDegradedSubscriptionFiltering" name="test_models_endpoint_with_degraded_subscription_kube_token" time="15.206" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_single_subscription_auto_select" time="16.495" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_explicit_subscription_header" time="8.752" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_empty_subscription_header_value" time="4.413" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_models_filtered_by_subscription" time="4.772" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_deduplication_same_model_multiple_refs" time="9.207" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_different_modelrefs_same_model_id" time="62.213" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_multiple_distinct_models_in_subscription" time="17.934" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_user_token_returns_all_models" time="27.831" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_user_token_with_subscription_header_filters" time="9.062" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_empty_model_list" time="11.211" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_response_schema_matches_openapi" time="4.398" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_model_metadata_preserved" time="4.425" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_api_key_scoped_to_subscription" time="9.178" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_api_key_with_deleted_subscription_403" time="13.230" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_api_key_with_inaccessible_subscription_403" time="9.440" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_invalid_subscription_header_403" time="9.040" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_access_denied_to_subscription_403" time="9.704" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_api_key_ignores_subscription_header" time="16.307" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_multiple_api_keys_different_subscriptions" time="16.381" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_service_account_token_multiple_subs_no_header" time="27.485" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_service_account_token_multiple_subs_with_header" time="16.954" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_unauthenticated_request_401" time="0.022" /><testcase classname="test.e2e.tests.test_models_endpoint.TestModelsEndpoint" name="test_central_models_endpoint_exempt_from_rate_limiting" time="23.514" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelDiscovery" name="test_maasmodelref_created" time="22.315" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelDiscovery" name="test_reconciler_created_httproute" time="0.123" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelDiscovery" name="test_reconciler_created_backend_service" time="0.114" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelAuth" name="test_invalid_key_returns_401" time="0.056" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelAuth" name="test_no_key_returns_401" time="0.025" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelEgress" name="test_request_forwarded_returns_200" time="0.145" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelCleanup" name="test_delete_removes_httproute" time="12.649" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelPathRouting" name="test_wrong_path_returns_not_found" time="0.026" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelBodyRouting" name="test_correct_model_in_body_succeeds" time="0.129" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelBodyRouting" name="test_wrong_model_in_body_does_not_error" time="0.097" /><testcase classname="test.e2e.tests.test_external_models.TestExternalModelBodyRouting" name="test_missing_model_in_body_does_not_error" time="1.235" /><testcase classname="test.e2e.tests.test_tenant.TestTenantLifecycle" name="test_tenant_ready_and_phase_healthy" time="0.361" /><testcase classname="test.e2e.tests.test_tenant.TestTenantLifecycle" name="test_payload_processing_deployed_with_active_tenant" time="0.227" /><testcase classname="test.e2e.tests.test_tenant.TestTenantContract" name="test_status_has_phase_and_conditions" time="0.111" /><testcase classname="test.e2e.tests.test_tenant.TestTenantContract" name="test_spec_is_well_formed" time="0.115" /><testcase classname="test.e2e.tests.test_tenant.TestTenantContract" name="test_conditions_use_kubernetes_metav1_shape" time="0.112" /><testcase classname="test.e2e.tests.test_tenant.TestTenantNoFalseOwnership" name="test_maas_user_crs_not_owned_by_tenant" time="0.341" /><testcase classname="test.e2e.tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_default_aitenant_bootstraps_maas_tenant_config_without_gateway_mutation" time="1.553" /><testcase classname="test.e2e.tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_rejected_outside_ai_tenants_namespace" time="6.223" /><testcase classname="test.e2e.tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_create_bootstrap_resources" time="43.987" /><testcase classname="test.e2e.tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_migrates_legacy_tenant_to_maas_tenant_config" time="35.227" /><testcase classname="test.e2e.tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_delete_cleans_maas_resources_and_preserves_user_objects" time="35.286" /><testcase classname="test.e2e.tests.test_aitenant_lifecycle.TestAITenantLifecycle" name="test_aitenant_derives_non_default_tenant_namespace" time="34.235" /><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestTenantNamespaceDiscovery" name="test_labeled_tenant_namespace_is_discovered" time="28.669" /><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestTenantNamespaceDiscovery" name="test_label_removal_stops_reconciliation" time="32.822" /><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestTenantNamespaceDiscovery" name="test_unlabeled_namespace_ignored" time="21.846" /><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestTenantNamespaceDiscovery" name="test_dynamic_discovery_after_label_added" time="27.728" /><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestTenantNamespaceDiscovery" name="test_per_tenant_oidc_configuration" time="0.001"><skipped type="pytest.skip" message="OIDC_ISSUER_URL not set; per-tenant OIDC E2E requires external OIDC deploy">/workspace/source/test/e2e/tests/test_tenant_namespace_discovery.py:186: OIDC_ISSUER_URL not set; per-tenant OIDC E2E requires external OIDC deploy</skipped></testcase><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestTenantNamespaceDiscovery" name="test_namespace_qualified_collision_prevention" time="593.726"><failure message="AssertionError: tokenratelimitpolicy/maas-trlp-facebook-opt-125m-simulated in llm did not satisfy condition. Last object: {'apiVersion': 'kuadrant.io/v1alpha1', 'kind': 'TokenRateLimitPolicy', 'metadata': {'annotations': {'maas.opendatahub.io/subscriptions': 'models-as-a-service/simulator-subscription'}, 'creationTimestamp': '2026-07-29T20:49:41Z', 'generation': 19, 'labels': {'app.kubernetes.io/component': 'token-rate-limit-policy', 'app.kubernetes.io/managed-by': 'maas-controller', 'app.kubernetes.io/part-of': 'maas-subscription', 'maas.opendatahub.io/model': 'facebook-opt-125m-simulated', 'maas.opendatahub.io/model-namespace': 'llm'}, 'name': 'maas-trlp-facebook-opt-125m-simulated', 'namespace': 'llm', 'ownerReferences': [{'apiVersion': 'gateway.networking.k8s.io/v1', 'blockOwnerDeletion': True, 'controller': True, 'kind': 'HTTPRoute', 'name': 'facebook-opt-125m-simulated-kserve-route', 'uid': 'd4d58868-808a-4316-9501-2b6da3758e92'}], 'resourceVersion': '51322', 'uid': '01208906-0b45-42d9-b973-a3c502335568'}, 'spec': {'limits': {'models-as-a-service-simulator-subscription-facebook-opt-125m-simulated-tokens': {'counters': [{'expression': 'auth.identity.userid'}], 'rates': [{'limit': 100, 'window': '1m'}], 'when': [{'predicate': 'auth.identity.selected_subscription_key == &quot;models-as-a-service/simulator-subscription@llm/facebook-opt-125m-simulated&quot; &amp;&amp; !request.path.endsWith(&quot;/v1/models&quot;)'}]}}, 'targetRef': {'group': 'gateway.networking.k8s.io', 'kind': 'HTTPRoute', 'name': 'facebook-opt-125m-simulated-kserve-route'}}, 'status': {'conditions': [{'lastTransitionTime': '2026-07-29T20:49:46Z', 'message': 'TokenRateLimitPolicy has been accepted', 'reason': 'Accepted', 'status': 'True', 'type': 'Accepted'}, {'lastTransitionTime': '2026-07-29T21:01:06Z', 'message': 'TokenRateLimitPolicy has been successfully enforced', 'reason': 'Enforced', 'status': 'True', 'type': 'Enforced'}], 'observedGeneration': 19}}">self = &lt;test_tenant_namespace_discovery.TestTenantNamespaceDiscovery object at 0x7fb1a3a9d490&gt;

    def test_namespace_qualified_collision_prevention(self):
        """1.5: Same-named CRs in two tenant namespaces use namespace-qualified TRLP tracking."""
        case_a = new_discovery_case()
        case_b = new_discovery_case()
        shared_policy_name = f"e2e-shared-policy-{case_a['suffix']}"
        shared_sub_name = f"e2e-shared-sub-{case_a['suffix']}"
        case_a["policy_name"] = shared_policy_name
        case_a["subscription_name"] = shared_sub_name
        case_b["policy_name"] = shared_policy_name
        case_b["subscription_name"] = shared_sub_name
    
        try:
            for case in (case_a, case_b):
                bootstrap_aitenant_tenant(case)
                apply_maas_auth_policy(shared_policy_name, case["tenant_ns"])
                apply_maas_subscription(shared_sub_name, case["tenant_ns"])
                wait_for_finalizer("maasauthpolicy", shared_policy_name, case["tenant_ns"], FINALIZER_AUTHPOLICY)
                wait_for_finalizer("maassubscription", shared_sub_name, case["tenant_ns"], FINALIZER_SUBSCRIPTION)
                _wait_for_maas_auth_policy_phase(shared_policy_name, namespace=case["tenant_ns"], timeout=120,
                                                 require_enforced=False)
    
            assert_no_per_model_authpolicy(MODEL_REF, MODEL_NAMESPACE)
    
            expected_a_sub = f"{case_a['tenant_ns']}/{shared_sub_name}"
            expected_b_sub = f"{case_b['tenant_ns']}/{shared_sub_name}"
&gt;           sub_contributors = wait_for_annotation_contains(
                "tokenratelimitpolicy",
                f"maas-trlp-{MODEL_REF}",
                MODEL_NAMESPACE,
                "maas.opendatahub.io/subscriptions",
                [expected_a_sub, expected_b_sub],
            )

test/e2e/tests/test_tenant_namespace_discovery.py:232: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/e2e/tests/multitenancy_helpers.py:358: in wait_for_annotation_contains
    wait_for_json(kind, name, namespace, predicate=_predicate, timeout=timeout, interval=interval)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

kind = 'tokenratelimitpolicy', name = 'maas-trlp-facebook-opt-125m-simulated'
namespace = 'llm'

    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: tokenratelimitpolicy/maas-trlp-facebook-opt-125m-simulated in llm did not satisfy condition. Last object: {'apiVersion': 'kuadrant.io/v1alpha1', 'kind': 'TokenRateLimitPolicy', 'metadata': {'annotations': {'maas.opendatahub.io/subscriptions': 'models-as-a-service/simulator-subscription'}, 'creationTimestamp': '2026-07-29T20:49:41Z', 'generation': 19, 'labels': {'app.kubernetes.io/component': 'token-rate-limit-policy', 'app.kubernetes.io/managed-by': 'maas-controller', 'app.kubernetes.io/part-of': 'maas-subscription', 'maas.opendatahub.io/model': 'facebook-opt-125m-simulated', 'maas.opendatahub.io/model-namespace': 'llm'}, 'name': 'maas-trlp-facebook-opt-125m-simulated', 'namespace': 'llm', 'ownerReferences': [{'apiVersion': 'gateway.networking.k8s.io/v1', 'blockOwnerDeletion': True, 'controller': True, 'kind': 'HTTPRoute', 'name': 'facebook-opt-125m-simulated-kserve-route', 'uid': 'd4d58868-808a-4316-9501-2b6da3758e92'}], 'resourceVersion': '51322', 'uid': '01208906-0b45-42d9-b973-a3c502335568'}, 'spec': {'limits': {'models-as-a-service-simulator-subscription-facebook-opt-125m-simulated-tokens': {'counters': [{'expression': 'auth.identity.userid'}], 'rates': [{'limit': 100, 'window': '1m'}], 'when': [{'predicate': 'auth.identity.selected_subscription_key == "models-as-a-service/simulator-subscription@llm/facebook-opt-125m-simulated" &amp;&amp; !request.path.endsWith("/v1/models")'}]}}, 'targetRef': {'group': 'gateway.networking.k8s.io', 'kind': 'HTTPRoute', 'name': 'facebook-opt-125m-simulated-kserve-route'}}, 'status': {'conditions': [{'lastTransitionTime': '2026-07-29T20:49:46Z', 'message': 'TokenRateLimitPolicy has been accepted', 'reason': 'Accepted', 'status': 'True', 'type': 'Accepted'}, {'lastTransitionTime': '2026-07-29T21:01:06Z', 'message': 'TokenRateLimitPolicy has been successfully enforced', 'reason': 'Enforced', 'status': 'True', 'type': 'Enforced'}], 'observedGeneration': 19}}

test/e2e/tests/multitenancy_helpers.py:227: AssertionError</failure></testcase><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestTenantNamespaceDiscovery" name="test_tenant_admin_rbac_is_namespace_scoped" time="32.807" /><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestTenantWebhookValidation" name="test_maassubscription_rejected_without_tenant_config_cr" time="6.258" /><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestTenantWebhookValidation" name="test_maasauthpolicy_rejected_without_tenant_config_cr" time="5.853" /><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestTenantDiscoveryDormantMode" name="test_dormant_mode_ignores_labeled_namespace" time="0.001"><skipped type="pytest.skip" message="Dormant-mode test mutates controller flags; set ENABLE_TENANT_DISCOVERY_DORMANT_E2E=true">/workspace/source/test/e2e/tests/test_tenant_namespace_discovery.py:352: Dormant-mode test mutates controller flags; set ENABLE_TENANT_DISCOVERY_DORMANT_E2E=true</skipped></testcase><testcase classname="test.e2e.tests.test_tenant_namespace_discovery.TestLegacyDefaultNamespaceStillWorks" name="test_models_as_a_service_namespace_reconciles" time="0.604" /><testcase classname="test.e2e.tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyStructure" name="test_target_ref_points_to_gateway" time="0.233" /><testcase classname="test.e2e.tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyStructure" name="test_no_per_model_authpolicy_for_fixture_model" time="0.122" /><testcase classname="test.e2e.tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyLifecycle" name="test_gateway_auth_embeds_model_allowlist" time="15.372" /><testcase classname="test.e2e.tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyLifecycle" name="test_only_one_gateway_authpolicy_named_maas_gateway_auth" time="0.228" /><testcase classname="test.e2e.tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyManagementEndpointAccess" name="test_gateway_auth_rego_allows_empty_model_identity" time="0.124" /><testcase classname="test.e2e.tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyManagementEndpointAccess" name="test_gateway_auth_subscription_check_gated_by_model_identity" time="0.118" /><testcase classname="test.e2e.tests.test_gateway_scoped_authpolicy.TestGatewayAuthPolicyManagementEndpointAccess" name="test_gateway_default_auth_scoped_if_present" time="0.113"><skipped type="pytest.skip" message="gateway-default-auth not present (maas-gateway-auth is active); scoping is validated by unit tests">/workspace/source/test/e2e/tests/test_gateway_scoped_authpolicy.py:183: gateway-default-auth not present (maas-gateway-auth is active); scoping is validated by unit tests</skipped></testcase><testcase classname="test.e2e.tests.test_gateway_scoped_authpolicy.TestEnforcementGapAfterAuthPolicyChange" name="test_controller_holds_pending_while_unenforced" time="115.402" /><testcase classname="test.e2e.tests.test_multi_tenant_integration.TestMultiTenantIntegration" name="test_full_tenant_lifecycle_create_to_delete" time="135.793" /><testcase classname="test.e2e.tests.test_multi_tenant_integration.TestMultiTenantIntegration" name="test_default_tenant_unaffected_by_multitenancy_enablement" time="21.467" /><testcase classname="test.e2e.tests.test_multi_tenant_integration.TestMultiTenantIntegration" name="test_same_named_resources_across_tenants" time="587.542"><failure message="AssertionError: tokenratelimitpolicy/maas-trlp-facebook-opt-125m-simulated in llm did not satisfy condition. Last object: {'apiVersion': 'kuadrant.io/v1alpha1', 'kind': 'TokenRateLimitPolicy', 'metadata': {'annotations': {'maas.opendatahub.io/subscriptions': 'models-as-a-service/simulator-subscription'}, 'creationTimestamp': '2026-07-29T20:49:41Z', 'generation': 23, 'labels': {'app.kubernetes.io/component': 'token-rate-limit-policy', 'app.kubernetes.io/managed-by': 'maas-controller', 'app.kubernetes.io/part-of': 'maas-subscription', 'maas.opendatahub.io/model': 'facebook-opt-125m-simulated', 'maas.opendatahub.io/model-namespace': 'llm'}, 'name': 'maas-trlp-facebook-opt-125m-simulated', 'namespace': 'llm', 'ownerReferences': [{'apiVersion': 'gateway.networking.k8s.io/v1', 'blockOwnerDeletion': True, 'controller': True, 'kind': 'HTTPRoute', 'name': 'facebook-opt-125m-simulated-kserve-route', 'uid': 'd4d58868-808a-4316-9501-2b6da3758e92'}], 'resourceVersion': '64476', 'uid': '01208906-0b45-42d9-b973-a3c502335568'}, 'spec': {'limits': {'models-as-a-service-simulator-subscription-facebook-opt-125m-simulated-tokens': {'counters': [{'expression': 'auth.identity.userid'}], 'rates': [{'limit': 100, 'window': '1m'}], 'when': [{'predicate': 'auth.identity.selected_subscription_key == &quot;models-as-a-service/simulator-subscription@llm/facebook-opt-125m-simulated&quot; &amp;&amp; !request.path.endsWith(&quot;/v1/models&quot;)'}]}}, 'targetRef': {'group': 'gateway.networking.k8s.io', 'kind': 'HTTPRoute', 'name': 'facebook-opt-125m-simulated-kserve-route'}}, 'status': {'conditions': [{'lastTransitionTime': '2026-07-29T20:49:46Z', 'message': 'TokenRateLimitPolicy has been accepted', 'reason': 'Accepted', 'status': 'True', 'type': 'Accepted'}, {'lastTransitionTime': '2026-07-29T21:16:34Z', 'message': 'TokenRateLimitPolicy has been successfully enforced', 'reason': 'Enforced', 'status': 'True', 'type': 'Enforced'}], 'observedGeneration': 23}}">self = &lt;test_multi_tenant_integration.TestMultiTenantIntegration object at 0x7fb1a42150a0&gt;

    def test_same_named_resources_across_tenants(self):
        """7.3: Same-named MaaS resources in separate tenant namespaces both contribute safely."""
        case_a = new_discovery_case()
        case_b = new_discovery_case()
        shared_policy = f"e2e-shared-int-policy-{case_a['suffix']}"
        shared_sub = f"e2e-shared-int-sub-{case_a['suffix']}"
        for case in (case_a, case_b):
            case["policy_name"] = shared_policy
            case["subscription_name"] = shared_sub
    
        try:
            for case in (case_a, case_b):
                bootstrap_aitenant_tenant(case)
                apply_maas_auth_policy(shared_policy, case["tenant_ns"])
                apply_maas_subscription(shared_sub, case["tenant_ns"])
                wait_for_finalizer("maasauthpolicy", shared_policy, case["tenant_ns"], FINALIZER_AUTHPOLICY)
                wait_for_finalizer("maassubscription", shared_sub, case["tenant_ns"], FINALIZER_SUBSCRIPTION)
                wait_for_status_phase("maasauthpolicy", shared_policy, case["tenant_ns"], expected_phase="Active")
    
            expected_subs = [f"{case_a['tenant_ns']}/{shared_sub}", f"{case_b['tenant_ns']}/{shared_sub}"]
&gt;           wait_for_annotation_contains(
                "tokenratelimitpolicy",
                f"maas-trlp-{MODEL_REF}",
                MODEL_NAMESPACE,
                "maas.opendatahub.io/subscriptions",
                expected_subs,
            )

test/e2e/tests/test_multi_tenant_integration.py:188: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/e2e/tests/multitenancy_helpers.py:358: in wait_for_annotation_contains
    wait_for_json(kind, name, namespace, predicate=_predicate, timeout=timeout, interval=interval)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

kind = 'tokenratelimitpolicy', name = 'maas-trlp-facebook-opt-125m-simulated'
namespace = 'llm'

    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: tokenratelimitpolicy/maas-trlp-facebook-opt-125m-simulated in llm did not satisfy condition. Last object: {'apiVersion': 'kuadrant.io/v1alpha1', 'kind': 'TokenRateLimitPolicy', 'metadata': {'annotations': {'maas.opendatahub.io/subscriptions': 'models-as-a-service/simulator-subscription'}, 'creationTimestamp': '2026-07-29T20:49:41Z', 'generation': 23, 'labels': {'app.kubernetes.io/component': 'token-rate-limit-policy', 'app.kubernetes.io/managed-by': 'maas-controller', 'app.kubernetes.io/part-of': 'maas-subscription', 'maas.opendatahub.io/model': 'facebook-opt-125m-simulated', 'maas.opendatahub.io/model-namespace': 'llm'}, 'name': 'maas-trlp-facebook-opt-125m-simulated', 'namespace': 'llm', 'ownerReferences': [{'apiVersion': 'gateway.networking.k8s.io/v1', 'blockOwnerDeletion': True, 'controller': True, 'kind': 'HTTPRoute', 'name': 'facebook-opt-125m-simulated-kserve-route', 'uid': 'd4d58868-808a-4316-9501-2b6da3758e92'}], 'resourceVersion': '64476', 'uid': '01208906-0b45-42d9-b973-a3c502335568'}, 'spec': {'limits': {'models-as-a-service-simulator-subscription-facebook-opt-125m-simulated-tokens': {'counters': [{'expression': 'auth.identity.userid'}], 'rates': [{'limit': 100, 'window': '1m'}], 'when': [{'predicate': 'auth.identity.selected_subscription_key == "models-as-a-service/simulator-subscription@llm/facebook-opt-125m-simulated" &amp;&amp; !request.path.endsWith("/v1/models")'}]}}, 'targetRef': {'group': 'gateway.networking.k8s.io', 'kind': 'HTTPRoute', 'name': 'facebook-opt-125m-simulated-kserve-route'}}, 'status': {'conditions': [{'lastTransitionTime': '2026-07-29T20:49:46Z', 'message': 'TokenRateLimitPolicy has been accepted', 'reason': 'Accepted', 'status': 'True', 'type': 'Accepted'}, {'lastTransitionTime': '2026-07-29T21:16:34Z', 'message': 'TokenRateLimitPolicy has been successfully enforced', 'reason': 'Enforced', 'status': 'True', 'type': 'Enforced'}], 'observedGeneration': 23}}

test/e2e/tests/multitenancy_helpers.py:227: AssertionError</failure></testcase><testcase classname="test.e2e.tests.test_multi_tenant_integration.TestMultiTenantIntegration" name="test_tenant_namespace_label_change_triggers_reconciliation" time="39.274" /><testcase classname="test.e2e.tests.test_tenant_model_inference.TestTenantModelInference" name="test_model_routes_through_tenant_gateway" time="125.871" /><testcase classname="test.e2e.tests.test_tenant_model_inference.TestTenantModelInference" name="test_inference_succeeds_through_tenant_gateway" time="4.281" /><testcase classname="test.e2e.tests.test_tenant_model_inference.TestTenantModelInference" name="test_tenant_isolation_cross_gateway_blocked" time="0.335" /><testcase classname="test.e2e.tests.test_tenant_model_inference.TestTenantBodyRouting" name="test_correct_model_in_body_succeeds" time="4.203" /><testcase classname="test.e2e.tests.test_tenant_model_inference.TestTenantBodyRouting" name="test_wrong_model_in_body_rejected" time="4.200" /><testcase classname="test.e2e.tests.test_tenant_model_inference.TestTenantBodyRouting" name="test_missing_model_in_body_rejected" time="4.194" /><testcase classname="test.e2e.tests.test_tenant_model_inference.TestTenantBodyRouting" name="test_each_tenant_routes_to_own_model" time="46.870" /><testcase classname="test.e2e.tests.test_multi_tenant_maas_api.TestPerTenantMaaSAPI" name="test_aitenant_creates_dedicated_maas_api_infrastructure" time="58.934" /><testcase classname="test.e2e.tests.test_multi_tenant_maas_api.TestPerTenantMaaSAPI" name="test_tenant_name_environment_variable_set" time="0.225" /><testcase classname="test.e2e.tests.test_multi_tenant_maas_api.TestPerTenantMaaSAPI" name="test_service_routing_isolation" time="0.443" /><testcase classname="test.e2e.tests.test_multi_tenant_maas_api.TestPerTenantMaaSAPI" name="test_httproute_tenant_attachment" time="0.224" /><testcase classname="test.e2e.tests.test_multi_tenant_maas_api.TestPerTenantMaaSAPI" name="test_default_and_multiple_tenants_coexist" time="38.561" /><testcase classname="test.e2e.tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_creation_scoped_to_tenant" time="148.398" /><testcase classname="test.e2e.tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_validates_against_correct_tenant" time="46.112" /><testcase classname="test.e2e.tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_rejected_cross_tenant" time="46.170" /><testcase classname="test.e2e.tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_oidc_token_validation_per_tenant" time="0.001"><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:212: 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="test.e2e.tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_list_scoped_to_tenant" time="44.093" /><testcase classname="test.e2e.tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_metadata_not_leaked_cross_tenant" time="46.232" /><testcase classname="test.e2e.tests.test_tenant_auth_isolation.TestTenantAuthIsolation" name="test_api_key_subscription_selection_uses_tenant_namespace" time="47.687" /><testcase classname="test.e2e.tests.test_tenant_subscription_isolation.TestTenantSubscriptionIsolation" name="test_subscription_list_scoped_to_tenant" time="140.353"><failure message="AssertionError: create API key for e2e-shared-a-5f7d51 failed: status=401 body=&#10;assert 401 in (200, 201)&#10; +  where 401 = &lt;Response [401]&gt;.status_code">self = &lt;test_tenant_subscription_isolation.TestTenantSubscriptionIsolation object at 0x7fb1a3a9b880&gt;
tenant_subscriptions = {'auth_policy': 'e2e-sub-iso-auth-94c627', 'shared': 'e2e-shared-sub-94c627', 'tenant_a': {'base_url': 'https://e2e-sh...est-model-5f7d51', 'model_namespace': 'ai-tenant-e2e-shared-a-5f7d51', ...}, 'tenant_a_only': 'e2e-a-only-94c627', ...}

    def test_subscription_list_scoped_to_tenant(self, tenant_subscriptions):
        """4.1: Subscription list contains current tenant subscriptions and excludes the other tenant."""
        tenant_a = tenant_subscriptions["tenant_a"]
        tenant_b = tenant_subscriptions["tenant_b"]
&gt;       key_a = _create_key_for_subscription(tenant_a, tenant_subscriptions["tenant_a_only"])

test/e2e/tests/test_tenant_subscription_isolation.py:165: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

tenant = {'base_url': 'https://e2e-shared-a-5f7d51.apps.311f226b-0216-4af9-8be8-bb8cffbdffc8.prod.konfluxeaas.com/maas-api', 'g... 'e2e-shared-a-5f7d51', 'model_name': 'sub-test-model-5f7d51', 'model_namespace': 'ai-tenant-e2e-shared-a-5f7d51', ...}
subscription = 'e2e-a-only-94c627'

    def _create_key_for_subscription(tenant: dict[str, str], subscription: str) -&gt; str:
        response = create_api_key_at(
            tenant["base_url"],
            _get_cluster_token(),
            f"e2e-sub-iso-{uuid.uuid4().hex[:6]}",
            subscription=subscription,
        )
&gt;       assert response.status_code in (200, 201), (
            f"create API key for {tenant['name']} failed: {response_summary(response)}"
        )
E       AssertionError: create API key for e2e-shared-a-5f7d51 failed: status=401 body=
E       assert 401 in (200, 201)
E        +  where 401 = &lt;Response [401]&gt;.status_code

test/e2e/tests/test_tenant_subscription_isolation.py:152: AssertionError</failure></testcase><testcase classname="test.e2e.tests.test_tenant_subscription_isolation.TestTenantSubscriptionIsolation" name="test_subscription_selection_per_tenant" time="78.431"><failure message="AssertionError: create API key for e2e-shared-a-5f7d51 failed: status=401 body=&#10;assert 401 in (200, 201)&#10; +  where 401 = &lt;Response [401]&gt;.status_code">self = &lt;test_tenant_subscription_isolation.TestTenantSubscriptionIsolation object at 0x7fb1a3a9b430&gt;
tenant_subscriptions = {'auth_policy': 'e2e-sub-iso-auth-c3309e', 'shared': 'e2e-shared-sub-c3309e', 'tenant_a': {'base_url': 'https://e2e-sh...est-model-5f7d51', 'model_namespace': 'ai-tenant-e2e-shared-a-5f7d51', ...}, 'tenant_a_only': 'e2e-a-only-c3309e', ...}

    def test_subscription_selection_per_tenant(self, tenant_subscriptions):
        """4.2: Same-named subscriptions resolve to the namespace behind each tenant endpoint."""
        shared = tenant_subscriptions["shared"]
        tenant_a = tenant_subscriptions["tenant_a"]
        tenant_b = tenant_subscriptions["tenant_b"]
&gt;       key_a = _create_key_for_subscription(tenant_a, shared)

test/e2e/tests/test_tenant_subscription_isolation.py:185: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

tenant = {'base_url': 'https://e2e-shared-a-5f7d51.apps.311f226b-0216-4af9-8be8-bb8cffbdffc8.prod.konfluxeaas.com/maas-api', 'g... 'e2e-shared-a-5f7d51', 'model_name': 'sub-test-model-5f7d51', 'model_namespace': 'ai-tenant-e2e-shared-a-5f7d51', ...}
subscription = 'e2e-shared-sub-c3309e'

    def _create_key_for_subscription(tenant: dict[str, str], subscription: str) -&gt; str:
        response = create_api_key_at(
            tenant["base_url"],
            _get_cluster_token(),
            f"e2e-sub-iso-{uuid.uuid4().hex[:6]}",
            subscription=subscription,
        )
&gt;       assert response.status_code in (200, 201), (
            f"create API key for {tenant['name']} failed: {response_summary(response)}"
        )
E       AssertionError: create API key for e2e-shared-a-5f7d51 failed: status=401 body=
E       assert 401 in (200, 201)
E        +  where 401 = &lt;Response [401]&gt;.status_code

test/e2e/tests/test_tenant_subscription_isolation.py:152: AssertionError</failure></testcase><testcase classname="test.e2e.tests.test_tenant_rate_limit_isolation.TestTenantRateLimitIsolation" name="test_rate_limit_enforced_per_tenant" time="165.600"><error message="failed on setup with &quot;AssertionError: status=401 body=&#10;assert 401 in (200, 201)&#10; +  where 401 = &lt;Response [401]&gt;.status_code&quot;">tenant_env = ({'backend_model_name': 'facebook/opt-125m', 'base_url': 'https://e2e-shared-a-5f7d51.apps.311f226b-0216-4af9-8be8-bb8...c8.prod.konfluxeaas.com/maas-api', 'gateway_name': 'e2e-shared-b-eee583', 'model_name': 'rate-test-model-eee583', ...})

    @pytest.fixture
    def tenant_rate_limit_setup(tenant_env):
        suffix = uuid.uuid4().hex[:6]
        tenant_a, tenant_b = tenant_env
        policy_name = f"e2e-rate-iso-auth-{suffix}"
        sub_a = f"e2e-rate-iso-a-{suffix}"
        sub_b = f"e2e-rate-iso-b-{suffix}"
        try:
            for tenant in tenant_env:
                apply_maas_auth_policy(
                    policy_name,
                    tenant["namespace"],
                    model_ref=tenant["model_name"],
                    model_namespace=tenant["model_namespace"],
                )
                wait_for_status_phase(
                    "maasauthpolicy",
                    policy_name,
                    tenant["namespace"],
                    expected_phase="Active",
                )
    
            for tenant in (tenant_a, tenant_b):
                wait_for_gateway_authpolicy_ready(tenant["gateway_name"])
    
            apply_maas_subscription(
                sub_a,
                tenant_a["namespace"],
                model_ref=tenant_a["model_name"],
                model_namespace=tenant_a["model_namespace"],
                token_limit=3,
                window="1m",
            )
            apply_maas_subscription(
                sub_b,
                tenant_b["namespace"],
                model_ref=tenant_b["model_name"],
                model_namespace=tenant_b["model_namespace"],
                token_limit=100,
                window="1m",
            )
            for name, namespace in ((sub_a, tenant_a["namespace"]), (sub_b, tenant_b["namespace"])):
                wait_for_status_phase(
                    "maassubscription",
                    name,
                    namespace,
                    expected_phase=("Active", "Degraded"),
                )
                _wait_for_subscription_trlp_status(
                    name,
                    expected_ready=True,
                    namespace=namespace,
                    timeout=120,
                )
            for tenant in (tenant_a, tenant_b):
                wait_for_status_phase(
                    "maasmodelref",
                    tenant["model_name"],
                    tenant["namespace"],
                    expected_phase="Ready",
                    timeout=180,
                )
    
            oc_token = _get_cluster_token()
            key_a_response = create_api_key_at(
                tenant_a["base_url"],
                oc_token,
                f"e2e-rate-a-{suffix}",
                subscription=sub_a,
            )
&gt;           assert key_a_response.status_code in (200, 201), response_summary(key_a_response)
E           AssertionError: status=401 body=
E           assert 401 in (200, 201)
E            +  where 401 = &lt;Response [401]&gt;.status_code

test/e2e/tests/test_tenant_rate_limit_isolation.py:128: AssertionError</error></testcase></testsuite></testsuites>