Running Sonar from Travis CI

This commit is contained in:
Aaron Louie 2020-02-12 10:34:34 -05:00
parent 760f2a1710
commit 5ecd06f7fe
3 changed files with 9 additions and 3 deletions

View File

@ -1,7 +1,6 @@
sonar.organization=sartography sonar.organization=sartography
sonar.projectKey=sartography_cr-connect-bpmn sonar.projectKey=sartography_cr-connect-bpmn
sonar.host.url=https://sonarcloud.io sonar.host.url=https://sonarcloud.io
sonar.login=f586bac67c1fe26a18700fa0ecf535e9c8a49bee
sonar.javascript.lcov.reportPaths=coverage/lcov.info sonar.javascript.lcov.reportPaths=coverage/lcov.info
sonar.typescript.tsconfigPath=tsconfig.json sonar.typescript.tsconfigPath=tsconfig.json
sonar.coverage.exclusions=**/*.mocks.ts, **/*.spec.ts, e2e/**, src/assets/**/*, src/main.ts, src/test.ts, src/polyfills.ts, karma.conf.js, docker/** sonar.coverage.exclusions=**/*.mocks.ts, **/*.spec.ts, e2e/**, src/assets/**/*, src/main.ts, src/test.ts, src/polyfills.ts, karma.conf.js, docker/**

View File

@ -5,18 +5,26 @@ addons:
chrome: stable chrome: stable
sonarcloud: sonarcloud:
organization: "sartography" organization: "sartography"
language: node_js language: node_js
node_js: node_js:
- 12 - 12
before_script: before_script:
- export DISPLAY=:99.0 - export DISPLAY=:99.0
- sh -e /etc/init.d/xvfb start - sh -e /etc/init.d/xvfb start
install: install:
- npm install - npm install
script: script:
- npm run ci - npm run ci
- sonar-scanner
before_deploy: before_deploy:
- docker build -t sartography/cr-connect-bpmn . - docker build -t sartography/cr-connect-bpmn .
deploy: deploy:
provider: script provider: script
script: bash ./docker/docker_push.sh script: bash ./docker/docker_push.sh

View File

@ -18,7 +18,7 @@
"e2e-wf:build": "cd docker && docker-compose pull && docker-compose build --no-cache && cd ..", "e2e-wf:build": "cd docker && docker-compose pull && docker-compose build --no-cache && cd ..",
"e2e-wf:start": "cd docker && docker-compose up -d && cd ..", "e2e-wf:start": "cd docker && docker-compose up -d && cd ..",
"e2e-wf": "npm run e2e-wf:stop && npm run e2e-wf:clean && npm run e2e-wf:build && npm run e2e-wf:start", "e2e-wf": "npm run e2e-wf:stop && npm run e2e-wf:clean && npm run e2e-wf:build && npm run e2e-wf:start",
"ci": "npm run lint && npm run test:coverage && npm run e2e:with-wf && sonar-scanner" "ci": "npm run lint && npm run test:coverage && npm run e2e:with-wf"
}, },
"private": true, "private": true,
"dependencies": { "dependencies": {
@ -77,7 +77,6 @@
"postcss-short": "^5.0.0", "postcss-short": "^5.0.0",
"protractor": "^5.4.2", "protractor": "^5.4.2",
"puppeteer": "^1.20.0", "puppeteer": "^1.20.0",
"sonar-scanner": "^3.1.0",
"ts-node": "~7.0.0", "ts-node": "~7.0.0",
"tslint": "~5.11.0", "tslint": "~5.11.0",
"typescript": "~3.5.3", "typescript": "~3.5.3",