Skip to content

Commit 9736de3

Browse files
error message changed
1 parent 653e76d commit 9736de3

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

bin/helpers/atsHelper.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,11 @@ exports.getTurboScaleGridDetails = async (bsConfig, args, rawArgs) => {
6969
responseData = {};
7070
}
7171
if(resp.statusCode != 200) {
72-
logger.warn(`Warn: Get Automate TurboScale Details Request failed with status code ${resp.statusCode}`);
72+
if (responseData.message == Constants.validationMessages.GRID_NOT_FOUND) {
73+
logger.error(`Error: Invalid grid name '${gridName}' specified.`);
74+
} else {
75+
logger.error(`Error:Failed to fetch turboscale grid details with response code ${resp.statusCode}`);
76+
};
7377
utils.sendUsageReport(bsConfig, args, responseData["error"], Constants.messageTypes.ERROR, 'get_ats_details_failed', null, rawArgs);
7478
resolve({});
7579
}

bin/helpers/constants.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,7 @@ const validationMessages = {
196196
"You have specified '--record' flag but you've not provided the '--record-key' and we could not find any value in 'CYPRESS_RECORD_KEY' environment variable. Your record functionality on cypress.io dashboard might not work as it needs the key and projectId",
197197
NODE_VERSION_PARSING_ERROR:
198198
"We weren't able to successfully parse the specified nodeVersion. We will be using the default nodeVersion to run your tests.",
199+
GRID_NOT_FOUND: "Not Found",
199200
};
200201

201202
const cliMessages = {

0 commit comments

Comments
 (0)