Skip to content
6 changes: 6 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,12 @@ jobs:
- run: ./canvas_modules/common-canvas/build.sh
- run: ./canvas_modules/harness/build.sh test
- run: ./canvas_modules/harness/functional_test.sh
if: github.ref == 'refs/heads/main'
- name: SonarCloud Scan
uses: SonarSource/sonarcloud-github-action@v1
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
GIT_TOKEN: ${{ secrets.GIT_TOKEN }}

tag:
runs-on: ubuntu-latest
Expand Down
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,13 @@ See [here](https://github.com/elyra-ai/canvas/tree/main/canvas_modules/harness)
* Elyra canvas documentation - https://elyra-ai.github.io/canvas/
* Elyra canvas playground (Test harness) - https://ibm.biz/elyra-canvas-test-harness

## Quality and Coverage
We use SonarCloud to ensure code quality and maintain high test coverage. You can view the detailed analysis and results by following the link below:

[![SonarCloud](https://sonarcloud.io/api/project_badges/measure?project=elyra-ai_canvas&metric=alert_status)](https://sonarcloud.io/dashboard?id=elyra-ai_canvas)

[View SonarCloud Results](https://sonarcloud.io/dashboard?id=elyra-ai_canvas)

## Using local version of common-canvas and/or common-properties
Clone elyra/canvas
```sh
Expand Down
8 changes: 8 additions & 0 deletions sonar-project.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
sonar.projectKey=elyra-ai_canvas

# relative paths to source directories. More details and properties are described
# in https://sonarcloud.io/documentation/project-administration/narrowing-the-focus/
sonar.sources=canvas_modules/common-canvas/src
sonar.tests=canvas_modules/common-canvas/__tests__
sonar.javascript.lcov.reportPaths=canvas_modules/common-canvas/coverage/lcov.info
sonar.verbose=true