Skip to content

Commit 2f71cd4

Browse files
author
Karan Nagpal
committed
add logging if skipping uploading
1 parent 0587f03 commit 2f71cd4

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

bin/helpers/constants.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,8 @@ const userMessages = {
4343
UPLOADING_TESTS_SUCCESS: "Uploaded tests successfully",
4444
UPLOADING_NPM_PACKAGES: "Uploading required node_modules to BrowserStack",
4545
UPLOADING_NPM_PACKAGES_SUCCESS: "Uploaded node_modules successfully",
46+
SKIP_UPLOADING_TESTS: "Skipping zip upload since BrowserStack already has your test suite that has not changed since the last run.",
47+
SKIP_UPLOADING_NPM_PACKAGES: "Skipping the upload of node_modules since BrowserStack has already cached your npm dependencies that have not changed since the last run.",
4648
LOCAL_TRUE: "you will now be able to test localhost / private URLs",
4749
LOCAL_FALSE: "you won't be able to test localhost / private URLs",
4850
EXIT_SYNC_CLI_MESSAGE: "Exiting the CLI, but your build is still running. You can use the --sync option to keep getting test updates. You can also use the build-info <build-id> command now.",

bin/helpers/zipUpload.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,9 @@ const uploadCypressZip = (bsConfig, md5data, packageData) => {
105105
const zipOptions = utils.generateUploadOptions('zip', md5data, packageData);
106106
const npmOptions = utils.generateUploadOptions('npm', md5data, packageData);
107107

108+
if(zipOptions.urlPresent) logger.info(Constants.userMessages.SKIP_UPLOADING_TESTS);
109+
if(npmOptions.urlPresent) logger.info(Constants.userMessages.SKIP_UPLOADING_NPM_PACKAGES);
110+
108111
if (!zipOptions.urlPresent && zipOptions.archivePresent) {
109112
logger.info(zipOptions.messages.uploading);
110113
}

0 commit comments

Comments
 (0)