Skip to content

Update SonarCloud configuration #2774

Update SonarCloud configuration

Update SonarCloud configuration #2774

Workflow file for this run

name: Flutter
on:
push:
branches:
- master
pull_request:
branches-ignore:
- release/beta
- release/master
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
unit_test:
name: Unit test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0 # for SonarCloud
- uses: actions/dependency-review-action@3b139cfc5fae8b618d3eae3675e383bb1769c019 # v4.5.0
if: github.base_ref
- name: Setup Flutter
uses: subosito/flutter-action@f2c4f6686ca8e8d6e6d0f28410eeef506ed66aff # v2.18.0
with:
cache: true
# TODO: investigate why this fail on GitHub Actions
# - run: dart format --set-exit-if-changed --output none .
- name: Run chromedriver
run: |
set -e
chromedriver --port=4444 &
echo CHROMEDRIVER_PORT_4444=yes >$GITHUB_ENV
- run: ./tool/test.sh --coverage
- uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
if: failure()
with:
name: failures
path: "**/failures/"
- uses: SonarSource/sonarqube-scan-action@0303d6b62e310685c0e34d0b9cde218036885c4d # v5.0.0
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}