Skip to content

Commit

Permalink
chore: reboot/cherry pick in v3 (zowe#3607)
Browse files Browse the repository at this point in the history
* fix: UI titles and message consistency (zowe#3502)

Signed-off-by: sj895092 <[email protected]>

* add bootRun debug default options (zowe#3595)

Signed-off-by: sj895092 <[email protected]>

* attempt at fixing flaky test (zowe#3596)

Signed-off-by: Pablo Hernán Carle <[email protected]>
Co-authored-by: Pablo Hernán Carle <[email protected]>

* update working dir in bootrun task (zowe#3602)

Signed-off-by: sj895092 <[email protected]>

* removed metrics service related test

Signed-off-by: sj895092 <[email protected]>

* chore: protect conformance endpoints and add them to Swagger (zowe#3604)

* protect endpoints

Signed-off-by: at670475 <[email protected]>

* add conformance to swagger

Signed-off-by: at670475 <[email protected]>

* add test

Signed-off-by: at670475 <[email protected]>

---------

Signed-off-by: at670475 <[email protected]>

* chore: protect conformance endpoints and add them to Swagger (zowe#3604)

* protect endpoints

Signed-off-by: at670475 <[email protected]>

* add conformance to swagger

Signed-off-by: at670475 <[email protected]>

* add test

Signed-off-by: at670475 <[email protected]>

---------

Signed-off-by: at670475 <[email protected]>

* removing metric service reference

Signed-off-by: sj895092 <[email protected]>

* removing gateway changes from v2 cherry pick

Signed-off-by: sj895092 <[email protected]>

* reverting back changes in gateway service

Signed-off-by: sj895092 <[email protected]>

* reverting back changes in gateway service

Signed-off-by: sj895092 <[email protected]>

* reverting back conformance endpoint validation changes

Signed-off-by: sj895092 <[email protected]>

* reverting back conformance endpoint validation changes

Signed-off-by: sj895092 <[email protected]>

---------

Signed-off-by: sj895092 <[email protected]>
Signed-off-by: Pablo Hernán Carle <[email protected]>
Signed-off-by: at670475 <[email protected]>
Co-authored-by: Jakub Balhar <[email protected]>
Co-authored-by: Pablo Carle <[email protected]>
Co-authored-by: Pablo Hernán Carle <[email protected]>
Co-authored-by: Andrea Tabone <[email protected]>
  • Loading branch information
5 people authored Jun 20, 2024
1 parent b8976cd commit 2246bf1
Show file tree
Hide file tree
Showing 11 changed files with 114 additions and 5 deletions.
9 changes: 9 additions & 0 deletions api-catalog-services/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,15 @@ bootRun {
if (project.hasProperty('args')) {
args project.args.split(',')
}

debugOptions {
port = 5014
suspend = false
server = true
}

workingDir = project.rootDir

systemProperties = System.properties
}

Expand Down
2 changes: 0 additions & 2 deletions api-catalog-ui/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,6 @@ task npmBuild(type: NpmTask) {

}



npmBuild.dependsOn npmInstall
npmBuild.dependsOn npmLint
build.dependsOn npmBuild
Expand Down
16 changes: 16 additions & 0 deletions caching-service/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -86,4 +86,20 @@ jar {
archiveClassifier = ""
}

bootRun {
if (project.hasProperty('args')) {
args project.args.split(',')
}

debugOptions {
port = 5016
suspend = false
server = true
}

workingDir = project.rootDir

systemProperties = System.properties
}

bootJar.archiveFileName = bootJar.archiveBaseName.get() + ".jar"
9 changes: 9 additions & 0 deletions cloud-gateway-service/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,15 @@ bootRun {
if (project.hasProperty('args')) {
args project.args.split(',')
}

debugOptions {
port = 5023
suspend = false
server = true
}

workingDir = project.rootDir

systemProperties = System.properties
}

Expand Down
16 changes: 16 additions & 0 deletions discoverable-client/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,22 @@ springBoot {
}
}

bootRun {
if (project.hasProperty('args')) {
args project.args.split(',')
}

debugOptions {
port = 5012
suspend = false
server = true
}

workingDir = project.rootDir

systemProperties = System.properties
}

gitProperties {
gitPropertiesDir = new File("${project.rootDir}/${name}/build/resources/main/META-INF")
}
Expand Down
9 changes: 9 additions & 0 deletions discovery-service/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,15 @@ bootRun {
if (project.hasProperty('args')) {
args project.args.split(',')
}

debugOptions {
port = 5011
suspend = false
server = true
}

workingDir = project.rootDir

systemProperties = System.properties
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ void testGetEndpoint() {
void testGetEndpointNonConformant() {
given()
.log().all()
.header("Cookie", "apimlAuthenticationToken=" + token)
.when()
.get(getEndpointURLGet() + "/nonConformantServiceBecauseNameIsTooLongAndContainsCapitalLettersqwertyuiop")
.then()
Expand All @@ -86,6 +87,33 @@ void testGetEndpointNonConformant() {

}

@Test
@TestsNotMeantForZowe
void testGetEndpointWithNoAuthentication() {
given()
.log().all()
.when()
.get(getEndpointURLGet() + "/discoverableclient")
.then()
.assertThat()
.statusCode(HttpStatus.SC_UNAUTHORIZED);

}

@Test
@TestsNotMeantForZowe
void testLegacyEndpointWithNoAuthentication() {
given()
.log().all()
.param("serviceID", "discoverableclient")
.when()
.post(getLegacyEndpointURLPost())
.then()
.assertThat()
.statusCode(HttpStatus.SC_UNAUTHORIZED);

}

private String getEndpointURLGet() {
GatewayServiceConfiguration gatewayServiceConfiguration = ConfigReader.environmentConfiguration().getGatewayServiceConfiguration();
String gatewayScheme = gatewayServiceConfiguration.getScheme();
Expand Down
16 changes: 16 additions & 0 deletions mock-services/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,22 @@ springBoot {
}
}

bootRun {
if (project.hasProperty('args')) {
args project.args.split(',')
}

debugOptions {
port = 5013
suspend = false
server = true
}

workingDir = project.rootDir

systemProperties = System.properties
}

gitProperties {
gitPropertiesDir = new File("${project.rootDir}/${name}/build/resources/main/META-INF")
}
Expand Down
9 changes: 9 additions & 0 deletions onboarding-enabler-spring-sample-app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -50,5 +50,14 @@ bootRun {
if (project.hasProperty('args')) {
args project.args.split(',')
}

debugOptions {
port = 5015
suspend = false
server = true
}

workingDir = project.rootDir

systemProperties = System.properties
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@
import {ResponseMock} from "../../__src__/ResponseMock";
import {Constants} from "../../../src/api/Constants";
import {expect, jest, describe, it} from '@jest/globals';
// Require the handler and create a new instance
const handlerReq = require("../../../src/cli/map/Map.handler");

describe("map handler unit tests", () => {

it("should accept options and return successful message", async () => {
// Require the handler and create a new instance
const handlerReq = require("../../../src/cli/map/Map.handler");
const handler = new handlerReq.default();

// Vars populated by the mocked function - error should remain undefined.
Expand Down
1 change: 0 additions & 1 deletion zowe-cli-id-federation-plugin/src/cli/map/Map.handler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ import {Constants} from "../../api/Constants";

export default class MapHandler implements ICommandHandler {


public async process(params: IHandlerParameters): Promise<void> {
const file: string = params.arguments.inputFile;
const system: string = params.arguments.system ?? '';
Expand Down

0 comments on commit 2246bf1

Please sign in to comment.