command start and end injector
parent
d2c92576f0
commit
178956ad5d
|
|
@ -2418,10 +2418,11 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
||||||
exports.CloudRunnerBuildCommandProcessor = void 0;
|
exports.CloudRunnerBuildCommandProcessor = void 0;
|
||||||
class CloudRunnerBuildCommandProcessor {
|
class CloudRunnerBuildCommandProcessor {
|
||||||
static ProcessCommands(commands) {
|
static ProcessCommands(commands) {
|
||||||
return `
|
return `echo "---"
|
||||||
echo "start"
|
echo "start"
|
||||||
${commands}
|
${commands}
|
||||||
echo "end"`;
|
echo "end"
|
||||||
|
`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
exports.CloudRunnerBuildCommandProcessor = CloudRunnerBuildCommandProcessor;
|
exports.CloudRunnerBuildCommandProcessor = CloudRunnerBuildCommandProcessor;
|
||||||
|
|
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -30,7 +30,9 @@ describe('Cloud Runner', () => {
|
||||||
buildParameter.logToFile = true;
|
buildParameter.logToFile = true;
|
||||||
const baseImage = new ImageTag(buildParameter);
|
const baseImage = new ImageTag(buildParameter);
|
||||||
await CloudRunner.run(buildParameter, baseImage.toString());
|
await CloudRunner.run(buildParameter, baseImage.toString());
|
||||||
const file = fs.readFileSync(`${CloudRunnerState.buildGuid}-outputfile.txt`, 'utf-8').toString();
|
const testOutput = `${CloudRunnerState.buildGuid}-outputfile.txt`;
|
||||||
|
expect(fs.existsSync(testOutput)).toBeTruthy();
|
||||||
|
const file = fs.readFileSync(testOutput, 'utf-8').toString();
|
||||||
expect(file).toContain(JSON.stringify(buildParameter));
|
expect(file).toContain(JSON.stringify(buildParameter));
|
||||||
expect(file).toContain(`${testSecretName}=${testSecretValue}`);
|
expect(file).toContain(`${testSecretName}=${testSecretValue}`);
|
||||||
const inputKeys = Object.getOwnPropertyNames(Input);
|
const inputKeys = Object.getOwnPropertyNames(Input);
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,9 @@
|
||||||
export class CloudRunnerBuildCommandProcessor {
|
export class CloudRunnerBuildCommandProcessor {
|
||||||
public static ProcessCommands(commands: string): string {
|
public static ProcessCommands(commands: string): string {
|
||||||
return `
|
return `echo "---"
|
||||||
echo "start"
|
echo "start"
|
||||||
${commands}
|
${commands}
|
||||||
echo "end"`;
|
echo "end"
|
||||||
|
`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue