Skip to content

Commit

Permalink
fix: sonar issues (#61)
Browse files Browse the repository at this point in the history
  • Loading branch information
andrejpetras authored Jul 19, 2024
1 parent 535e998 commit 1a0ef68
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 28 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,38 +47,38 @@ h| Version
| tkit-quarkus-log-cdi
| https://1000kit.github.io/tkit-quarkus/current/tkit-quarkus/tkit-quarkus-log-cdi.html[Link]
| https://github.com/1000kit/tkit-quarkus/blob/2.27.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-log-cdi.adoc[Link]
| 2.27.0
| https://github.com/1000kit/tkit-quarkus/blob/2.28.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-log-cdi.adoc[Link]
| 2.28.0
| tkit-quarkus-log-rs
| https://1000kit.github.io/tkit-quarkus/current/tkit-quarkus/tkit-quarkus-log-rs.html[Link]
| https://github.com/1000kit/tkit-quarkus/blob/2.27.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-log-rs.adoc[Link]
| 2.27.0
| https://github.com/1000kit/tkit-quarkus/blob/2.28.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-log-rs.adoc[Link]
| 2.28.0
| tkit-quarkus-log-json
| https://1000kit.github.io/tkit-quarkus/current/tkit-quarkus/tkit-quarkus-log-json.html[Link]
| https://github.com/1000kit/tkit-quarkus/blob/2.27.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-log-json.adoc[Link]
| 2.27.0
| https://github.com/1000kit/tkit-quarkus/blob/2.28.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-log-json.adoc[Link]
| 2.28.0
| tkit-quarkus-rest
| https://1000kit.github.io/tkit-quarkus/current/tkit-quarkus/tkit-quarkus-rest.html[Link]
| https://github.com/1000kit/tkit-quarkus/blob/2.27.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-rest.adoc[Link]
| 2.27.0
| https://github.com/1000kit/tkit-quarkus/blob/2.28.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-rest.adoc[Link]
| 2.28.0
| tkit-quarkus-rest-context
| https://1000kit.github.io/tkit-quarkus/current/tkit-quarkus/tkit-quarkus-rest-context.html[Link]
| https://github.com/1000kit/tkit-quarkus/blob/2.27.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-rest-context.adoc[Link]
| 2.27.0
| https://github.com/1000kit/tkit-quarkus/blob/2.28.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-rest-context.adoc[Link]
| 2.28.0
| tkit-quarkus-security
| https://1000kit.github.io/tkit-quarkus/current/tkit-quarkus/tkit-quarkus-security.html[Link]
| https://github.com/1000kit/tkit-quarkus/blob/2.27.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-security.adoc[Link]
| 2.27.0
| https://github.com/1000kit/tkit-quarkus/blob/2.28.0/docs/modules/tkit-quarkus/pages/includes/tkit-quarkus-security.adoc[Link]
| 2.28.0
| quarkus-hibernate-validator
Expand All @@ -89,8 +89,8 @@ h| Version
| onecx-permissions
| https://onecx.github.io/docs/onecx-quarkus/current/onecx-quarkus/onecx-permissions.html[Link]
| https://github.com/onecx/onecx-quarkus/blob/0.22.0/docs/modules/onecx-quarkus/pages/includes/onecx-permissions.adoc[Link]
| 0.22.0
| https://github.com/onecx/onecx-quarkus/blob/0.24.0/docs/modules/onecx-quarkus/pages/includes/onecx-permissions.adoc[Link]
| 0.24.0
| quarkus-oidc
Expand All @@ -102,7 +102,7 @@ h| Version
| https://onecx.github.io/docs/onecx-quarkus/current/onecx-quarkus/onecx-core.html[Link]
|
| 0.22.0
| 0.24.0
| quarkus-micrometer-registry-prometheus
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@ class UserRestControllerTest extends AbstractTest {
@InjectMockServerClient
MockServerClient mockServerClient;

final String TOKEN = keycloakClient.getAccessToken(ADMIN);
final String token = keycloakClient.getAccessToken(ADMIN);

@Test
void getUserRoles() {
var testToken = "Bearer " + TOKEN;
var testToken = "Bearer " + token;
RoleRequest roleRequest = new RoleRequest();
roleRequest.pageNumber(0).pageSize(5).token(testToken);

Expand All @@ -53,7 +53,7 @@ void getUserRoles() {

var output = given()
.when()
.auth().oauth2(TOKEN)
.auth().oauth2(token)
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(criteriaDTO)
Expand All @@ -70,7 +70,7 @@ void getUserRoles() {

@Test
void getUserPermissions() {
var testToken = "Bearer " + TOKEN;
var testToken = "Bearer " + token;

PermissionRequest permissionRequest = new PermissionRequest();
permissionRequest.pageNumber(0).pageSize(5).token(testToken);
Expand All @@ -90,7 +90,7 @@ void getUserPermissions() {

var output = given()
.when()
.auth().oauth2(TOKEN)
.auth().oauth2(token)
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(criteriaDTO)
Expand All @@ -107,7 +107,7 @@ void getUserPermissions() {

@Test
void getUserAssignments() {
var testToken = "Bearer " + TOKEN;
var testToken = "Bearer " + token;
AssignmentRequest assignmentRequest = new AssignmentRequest();
assignmentRequest.pageNumber(0).pageSize(5).token(testToken);

Expand All @@ -126,7 +126,7 @@ void getUserAssignments() {

var output = given()
.when()
.auth().oauth2(TOKEN)
.auth().oauth2(token)
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(criteriaDTO)
Expand All @@ -143,7 +143,7 @@ void getUserAssignments() {

@Test
void getUserRoles_BAD_REQUEST() {
var testToken = "Bearer " + TOKEN;
var testToken = "Bearer " + token;
RoleRequest roleRequest = new RoleRequest();
roleRequest.pageNumber(0).pageSize(5).token(testToken);

Expand All @@ -159,7 +159,7 @@ void getUserRoles_BAD_REQUEST() {

var output = given()
.when()
.auth().oauth2(TOKEN)
.auth().oauth2(token)
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(criteriaDTO)
Expand All @@ -174,7 +174,7 @@ void getUserRoles_BAD_REQUEST() {

@Test
void getUserPermissions_BAD_REQUEST() {
var testToken = "Bearer " + TOKEN;
var testToken = "Bearer " + token;

PermissionRequest permissionRequest = new PermissionRequest();
permissionRequest.pageNumber(0).pageSize(5).token(testToken);
Expand All @@ -191,7 +191,7 @@ void getUserPermissions_BAD_REQUEST() {

var output = given()
.when()
.auth().oauth2(TOKEN)
.auth().oauth2(token)
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(criteriaDTO)
Expand All @@ -205,7 +205,7 @@ void getUserPermissions_BAD_REQUEST() {

@Test
void getUserAssignments_BAD_REQUEST() {
var testToken = "Bearer " + TOKEN;
var testToken = "Bearer " + token;
AssignmentRequest assignmentRequest = new AssignmentRequest();
assignmentRequest.pageNumber(0).pageSize(5).token(testToken);

Expand All @@ -221,7 +221,7 @@ void getUserAssignments_BAD_REQUEST() {

var output = given()
.when()
.auth().oauth2(TOKEN)
.auth().oauth2(token)
.header(APM_HEADER_PARAM, ADMIN)
.contentType(APPLICATION_JSON)
.body(criteriaDTO)
Expand Down

0 comments on commit 1a0ef68

Please sign in to comment.