-
Notifications
You must be signed in to change notification settings - Fork 1
37 lines (29 loc) · 1.01 KB
/
Copy pathlint_and_test.yml
File metadata and controls
37 lines (29 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Lint and test the project
on:
pull_request:
types: [ opened, synchronize, edited, reopened, ready_for_review ]
jobs:
lint_and_test:
name: Static code analyze & Unit test
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
uses: actions/checkout@v3.3.0
- name: Set up Flutter version
uses: subosito/flutter-action@v1
with:
flutter-version: '3.3.8'
- name: Setup .env.staging
env:
ENV_STAGING: ${{ secrets.ENV_STAGING }}
run: echo $ENV_STAGING | base64 --decode >> .env.staging
- name: Get Flutter dependencies
run: flutter pub get
- name: Run code generator script
run: flutter packages pub run build_runner build --delete-conflicting-outputs
- name: Check for any formatting issues in the code
run: flutter format --set-exit-if-changed .
- name: Statically analyze the Dart code.
run: flutter analyze
- name: Run unit tests
run: flutter test