Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,18 +27,19 @@ jobs:
include:
- stage: build
script:
- npm test
- NODE_ENV=production node /home/travis/build/ioFog/Controller/src/main.js start
- npm run postman_test
- stage: dev_deploy
before_install:
- sudo apt-get install sshpass
script:
- sshpass -p $DEV_MACHINE_PASSWORD ssh -o StrictHostKeyChecking=no $DEV_MACHINE_USERNAME@$DEV_MACHINE_IP "cd /FogController; NODE_ENV=production node src/main.js stop; git pull; npm i; NODE_ENV=production node src/main.js start; npm run postman_test"
- sshpass -p $DEV_MACHINE_PASSWORD ssh -o StrictHostKeyChecking=no $DEV_MACHINE_USERNAME@$DEV_MACHINE_IP "cd /FogController; NODE_ENV=production node src/main.js stop; git pull; npm i; npm test; NODE_ENV=production node src/main.js start; npm run postman_test"
- stage: pre_release
before_install:
- sudo apt-get install sshpass
script:
- sshpass -p $PREPROD_MACHINE_PASSWORD ssh -o StrictHostKeyChecking=no $PREPROD_MACHINE_USERNAME@$PREPROD_MACHINE_IP "cd /Controller; NODE_ENV=production node src/main.js stop; git pull; npm i; NODE_ENV=production node src/main.js start; npm run postman_test"
- sshpass -p $PREPROD_MACHINE_PASSWORD ssh -o StrictHostKeyChecking=no $PREPROD_MACHINE_USERNAME@$PREPROD_MACHINE_IP "cd /Controller; NODE_ENV=production node src/main.js stop; git pull; npm i; npm test; NODE_ENV=production node src/main.js start; npm run postman_test"
- stage: release
#before_install:
#- git clone "https://github.com/$TRAVIS_REPO_SLUG.git" "$TRAVIS_REPO_SLUG";
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
"postinstall": "node scripts/postinstall.js",
"lint": "./node_modules/.bin/eslint \"**/*.js\"",
"automatic-release": "automatic-release",
"test": "node scripts/test.js",
"test": "node scripts/test.js && node scripts/cli-tests.js",
"postman_test": "node scripts/postmantest.js",
"cli-tests": "node scripts/cli-tests.js",
"coverage": "node scripts/coverage.js"
Expand Down
4 changes: 2 additions & 2 deletions scripts/cli-tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ function testConfigSection() {
// TODO backup config before this command
// hasSomeResponse(testCommand("config add -p 1234 -c testPath -k testSslPath -i testIntermediateCertPath" +
// " -h testHomeUrl -a testEmailAddress -w testEmailPassword -s testEmailService -d testLogDir -z 555"));
responseContains(testCommand('config list'), 'Port: 1234');
hasSomeResponse(testCommand('config list'));
responseEquals(testCommand('config dev-mode -o'), 'Dev mode state updated successfully.');
responseEquals(testCommand('config email-activation -f'), 'Email activation state updated successfully.');
}
Expand Down Expand Up @@ -298,7 +298,7 @@ function testDiagnosticsSection() {
"-C 15 -s 25 -F 27 -Q 26 -B -W -A -y 1 -u " + userId), ioFogCreateFields);
const ioFogUuid = ioFogCreateResponse.uuid;

const microserviceCreateResponse = responseHasFields(testCommand("microservice add -n microserviceName1" +
const microserviceCreateResponse = responseHasFields(executeCommand("microservice add -n microserviceName1" +
" -c " + catalogId + " -F " + flowId + " -I " + ioFogUuid + " -g '{}' -v /host_src:/container_src:rw -l 15 -R" +
" -p 80:8080:false -u " + userId), microserviceCreateFields);
const microserviceUuid = microserviceCreateResponse.uuid;
Expand Down