From 2ff3b6c824349fe77adb259427753fb586c8f748 Mon Sep 17 00:00:00 2001 From: Guillaume Smet Date: Fri, 16 Aug 2024 17:59:59 +0200 Subject: [PATCH] Fix ElytronOauth2ExtensionResourceTestCase The header should be: Authorization: Bearer and not Authorization: Bearer: (cherry picked from commit cd12e4ca79ad6d4be5ce31409debf2a2be0458be) --- .../oauth2/ElytronOauth2ExtensionResourceTestCase.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/integration-tests/elytron-security-oauth2/src/test/java/io/quarkus/it/elytron/oauth2/ElytronOauth2ExtensionResourceTestCase.java b/integration-tests/elytron-security-oauth2/src/test/java/io/quarkus/it/elytron/oauth2/ElytronOauth2ExtensionResourceTestCase.java index 496863baf8204..3a3797eabb130 100644 --- a/integration-tests/elytron-security-oauth2/src/test/java/io/quarkus/it/elytron/oauth2/ElytronOauth2ExtensionResourceTestCase.java +++ b/integration-tests/elytron-security-oauth2/src/test/java/io/quarkus/it/elytron/oauth2/ElytronOauth2ExtensionResourceTestCase.java @@ -56,7 +56,7 @@ public void authenticated() { ensureStarted(); RestAssured.given() .when() - .header("Authorization", "Bearer: " + BEARER_TOKEN) + .header("Authorization", "Bearer " + BEARER_TOKEN) .get("/api/authenticated") .then() .statusCode(200) @@ -78,7 +78,7 @@ public void forbidden() { ensureStarted(); RestAssured.given() .when() - .header("Authorization", "Bearer: " + BEARER_TOKEN) + .header("Authorization", "Bearer " + BEARER_TOKEN) .get("/api/forbidden") .then() .statusCode(403); @@ -99,13 +99,13 @@ public void testGrpcAuthorization() { ensureStarted(); RestAssured.given() .when() - .header("Authorization", "Bearer: " + BEARER_TOKEN) + .header("Authorization", "Bearer " + BEARER_TOKEN) .get("/api/grpc-writer") .then() .statusCode(500); RestAssured.given() .when() - .header("Authorization", "Bearer: " + BEARER_TOKEN) + .header("Authorization", "Bearer " + BEARER_TOKEN) .get("/api/grpc-reader") .then() .statusCode(200)