Skip to content

Commit

Permalink
Merge pull request #47 from wmedvede/remove-keycloack-dep-9.102.x-prod
Browse files Browse the repository at this point in the history
[9.102.x-prod] Remove un-needed dependency to keycloak-common
  • Loading branch information
fjtirado authored Nov 22, 2024
2 parents 31b49af + c426368 commit 9803366
Show file tree
Hide file tree
Showing 21 changed files with 6 additions and 86 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,6 @@
<artifactId>kogito-test-utils</artifactId>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
</dependency>
</dependencies>

</project>
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
import java.util.stream.Collectors;

import org.junit.jupiter.api.Test;
import org.keycloak.representations.AccessTokenResponse;
import org.kie.kogito.explainability.api.CounterfactualSearchDomain;
import org.kie.kogito.explainability.api.CounterfactualSearchDomainCollectionValue;
import org.kie.kogito.explainability.api.CounterfactualSearchDomainStructureValue;
Expand Down Expand Up @@ -183,7 +182,7 @@ public void doTest() {
.param(KEYCLOAK_CLIENT_SECRET_PARAM_NAME, KEYCLOAK_CLIENT_SECRET_PARAM_VALUE)
.when()
.post(KEYCLOAK_ACCESS_TOKEN_PATH)
.as(AccessTokenResponse.class).getToken();
.jsonPath().get("access_token");

assertNotNull(accessToken);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,11 +141,6 @@
<artifactId>json-unit-assertj</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.kie.kogito</groupId>
<artifactId>kogito-quarkus-test-utils</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@

import org.eclipse.microprofile.config.inject.ConfigProperty;
import org.junit.jupiter.api.Test;
import org.keycloak.representations.AccessTokenResponse;
import org.kie.kogito.testcontainers.KogitoKeycloakContainer;
import org.kie.kogito.testcontainers.quarkus.KeycloakQuarkusTestResource;

Expand Down Expand Up @@ -97,6 +96,6 @@ private String getAccessToken(String userName) {
.param("client_secret", KogitoKeycloakContainer.CLIENT_SECRET)
.when()
.post(keycloakURL + "/protocol/openid-connect/token")
.as(AccessTokenResponse.class).getToken();
.jsonPath().get("access_token");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,6 @@
<artifactId>kogito-quarkus-test-utils</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.awaitility</groupId>
<artifactId>awaitility</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,6 @@
<artifactId>kogito-quarkus-test-utils</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.awaitility</groupId>
<artifactId>awaitility</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,11 +95,6 @@
<artifactId>kogito-quarkus-test-utils</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.awaitility</groupId>
<artifactId>awaitility</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,6 @@
<artifactId>kogito-quarkus-test-utils</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.awaitility</groupId>
<artifactId>awaitility</artifactId>
Expand Down
5 changes: 0 additions & 5 deletions explainability/explainability-service-rest/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -86,11 +86,6 @@
<artifactId>kogito-quarkus-test-utils</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
</dependencies>

<build>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@

import org.apache.http.HttpStatus;
import org.junit.jupiter.api.Test;
import org.keycloak.representations.AccessTokenResponse;
import org.kie.kogito.test.quarkus.QuarkusTestProperty;
import org.kie.kogito.testcontainers.KogitoKeycloakContainer;
import org.kie.kogito.testcontainers.quarkus.KeycloakQuarkusTestResource;
Expand Down Expand Up @@ -65,6 +64,6 @@ private String getAccessToken(String userName) {
.param("client_secret", KogitoKeycloakContainer.CLIENT_SECRET)
.when()
.post(keycloakURL + "/protocol/openid-connect/token")
.as(AccessTokenResponse.class).getToken();
.jsonPath().get("access_token");
}
}
5 changes: 0 additions & 5 deletions jobs-service/jobs-service-common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -163,11 +163,6 @@
<artifactId>rest-assured</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-junit-jupiter</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.keycloak.representations.AccessTokenResponse;
import org.kie.kogito.jobs.api.Job;
import org.kie.kogito.jobs.api.JobBuilder;
import org.kie.kogito.jobs.service.model.JobStatus;
Expand Down Expand Up @@ -234,6 +233,6 @@ private String getAccessToken(String userName) {
.param("client_secret", KogitoKeycloakContainer.CLIENT_SECRET)
.when()
.post(keycloakURL + "/protocol/openid-connect/token")
.as(AccessTokenResponse.class).getToken();
.jsonPath().get("access_token");
}
}
5 changes: 0 additions & 5 deletions jobs-service/jobs-service-infinispan/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -114,11 +114,6 @@
<artifactId>rest-assured</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.github.tomakehurst</groupId>
<artifactId>wiremock-jre8</artifactId>
Expand Down
5 changes: 0 additions & 5 deletions jobs-service/jobs-service-inmemory/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -107,11 +107,6 @@
<artifactId>rest-assured</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.github.tomakehurst</groupId>
<artifactId>wiremock-jre8</artifactId>
Expand Down
5 changes: 0 additions & 5 deletions jobs-service/jobs-service-mongodb/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,6 @@
<artifactId>rest-assured</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.github.tomakehurst</groupId>
<artifactId>wiremock-jre8</artifactId>
Expand Down
5 changes: 0 additions & 5 deletions jobs-service/jobs-service-postgresql-common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -99,11 +99,6 @@
<artifactId>rest-assured</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.github.tomakehurst</groupId>
<artifactId>wiremock-jre8</artifactId>
Expand Down
5 changes: 0 additions & 5 deletions jobs-service/jobs-service-storage-jpa/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -113,11 +113,6 @@
<artifactId>rest-assured</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.github.tomakehurst</groupId>
<artifactId>wiremock-jre8</artifactId>
Expand Down
5 changes: 0 additions & 5 deletions security-commons/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,6 @@
<artifactId>kogito-quarkus-test-utils</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-junit5</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
package org.kie.kogito.security;

import org.junit.jupiter.api.Test;
import org.keycloak.representations.AccessTokenResponse;
import org.kie.kogito.test.quarkus.QuarkusTestProperty;
import org.kie.kogito.testcontainers.KogitoKeycloakContainer;
import org.kie.kogito.testcontainers.quarkus.KeycloakQuarkusTestResource;
Expand Down Expand Up @@ -74,6 +73,6 @@ private String getAccessToken(String userName) {
.param("client_secret", KogitoKeycloakContainer.CLIENT_SECRET)
.when()
.post(keycloakURL + "/protocol/openid-connect/token")
.as(AccessTokenResponse.class).getToken();
.jsonPath().get("access_token");
}
}
5 changes: 0 additions & 5 deletions trusty/trusty-service/trusty-service-common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -124,11 +124,6 @@
<artifactId>awaitility</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.skyscreamer</groupId>
<artifactId>jsonassert</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
import org.apache.http.HttpStatus;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.TestInstance;
import org.keycloak.representations.AccessTokenResponse;
import org.kie.kogito.test.quarkus.QuarkusTestProperty;
import org.kie.kogito.testcontainers.KogitoKeycloakContainer;
import org.kie.kogito.testcontainers.quarkus.KeycloakQuarkusTestResource;
Expand Down Expand Up @@ -77,6 +76,6 @@ private String getAccessToken(String userName) {
.param("client_secret", KogitoKeycloakContainer.CLIENT_SECRET)
.when()
.post(keycloakURL + "/protocol/openid-connect/token")
.as(AccessTokenResponse.class).getToken();
.jsonPath().get("access_token");
}
}

0 comments on commit 9803366

Please sign in to comment.