Skip to content

Commit

Permalink
add init trusts for airgap cluster
Browse files Browse the repository at this point in the history
  • Loading branch information
SkorikSergey committed Jan 7, 2025
1 parent f940950 commit fdd7b76
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions tests/e2e/specs/api/NodeJsExpressDevFileAPI.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,9 @@ suite('NodeJS Express devfile API test', function (): void {
const containerName: string = YAML.parse(devfileContent).commands[0].exec.component;

if (BASE_TEST_CONSTANTS.IS_CLUSTER_DISCONNECTED()) {
Logger.info('Test cluster is disconnected. Init Java Truststore...');
const initJavaTruststoreCommand: string =
'cp /home/user/init-java-truststore.sh /tmp && chmod +x /tmp/init-java-truststore.sh && /tmp/init-java-truststore.sh';
const output: ShellString = containerTerminal.execInContainerCommand(initJavaTruststoreCommand, containerName);
Logger.info('Test cluster is disconnected. Init NodeJS Truststore...');
const initNodeTruststoreCommand: string = 'npm config set strict-ssl false';
const output: ShellString = containerTerminal.execInContainerCommand(initNodeTruststoreCommand, containerName);
expect(output.code).eqls(0);
}

Expand All @@ -85,7 +84,7 @@ suite('NodeJS Express devfile API test', function (): void {
expect(output.code).eqls(0);

const outputText: string = output.stdout.trim();
expect(outputText).contains('Run `npm audit` for details.');
expect(outputText).contains('packages in');
});

test('Check "run the web app" command', function (): void {
Expand Down Expand Up @@ -114,7 +113,7 @@ suite('NodeJS Express devfile API test', function (): void {
Logger.info(`workdir from exec section of DevWorkspace file: ${workdir}`);
Logger.info(`commandLine from exec section of DevWorkspace file: ${commandLine}`);

// Prettier changes next line to `replaceAll("'", "'\"'\"'")` that throws an error from eslint.
// prettier changes next line to `replaceAll("'", "'\"'\"'")` that throws an error from eslint.
// prettier-ignore
let runCommandInBash: string = commandLine.replaceAll('\'', '\'\"\'\"\'');

Expand Down

0 comments on commit fdd7b76

Please sign in to comment.