prasule/.forgejo/workflows/sq_analyze.yml
Matyáš Caras 84f3e0f493
Some checks failed
/ build (push) Failing after 5m12s
ci: set up android
2024-07-17 21:16:36 +02:00

43 lines
No EOL
1.4 KiB
YAML

on:
push:
branches:
- 'dev'
env:
SONAR_TOKEN: ${{ secrets.SQ_KEY }}
jobs:
build:
runs-on: node22
steps:
- name: Initialize scanner
run: |
export SONAR_SCANNER_VERSION=6.0.0.4432
export SONAR_SCANNER_HOME=$HOME/.sonar/sonar-scanner-$SONAR_SCANNER_VERSION-linux
curl --create-dirs -sSLo $HOME/.sonar/sonar-scanner.zip https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-$SONAR_SCANNER_VERSION-linux.zip
unzip -o $HOME/.sonar/sonar-scanner.zip -d $HOME/.sonar/
export PATH=$SONAR_SCANNER_HOME/bin:$PATH
export SONAR_SCANNER_OPTS="-server"
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: Install dependencies
run: |
./flutterw channel beta
./flutterw pub get
- name: Setup Android SDK
uses: https://github.com/android-actions/setup-android@v3
with:
log-accepted-android-sdk-licenses: false
- name: Run tests
uses: https://github.com/ReactiveCircus/android-emulator-runner@v2
with:
api-level: ${{ vars.ANDROID_API }}
script: ./flutterw test integration_test/app_test.dart --coverage --reporter json > tests.output
- name: Run scanner
run: |
sonar-scanner