-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathautomatic_version_upgrader.yaml
More file actions
82 lines (62 loc) · 2.11 KB
/
automatic_version_upgrader.yaml
File metadata and controls
82 lines (62 loc) · 2.11 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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
name: automatic_version_upgrader
on:
pull_request:
paths:
- ".github/workflows/automatic_version_upgrader.yaml"
- "lib/**"
- "test/**"
- "pubspec.yaml"
push:
branches:
- main
paths:
- ".github/workflows/automatic_version_upgrader.yaml"
- "lib/**"
- "test/**"
- "pubspec.yaml"
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2.3.4
- uses: subosito/flutter-action@v1.5.3
- name: Install Dependencies
run: dart pub get
- name: Format
run: dart format --set-exit-if-changed .
- name: Analyze
run: dart analyze lib test
- name: Verify Build
run: dart run test --run-skipped -t pull-request-only
- name: Run Tests
run: |
dart pub global activate coverage 1.2.0
dart run test -j 1 -x pull-request-only -x e2e --coverage=coverage --test-randomize-ordering-seed random && dart pub global run coverage:format_coverage --lcov --in=coverage --out=coverage/lcov.info --packages=.packages --report-on=lib
- name: Check Code Coverage
uses: VeryGoodOpenSource/very_good_coverage@v1.2.0
e2e:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2.3.4
- uses: subosito/flutter-action@v1.5.3
- name: Install LCOV
run: sudo apt-get install -y lcov
- name: Install Dependencies
run: dart pub get
- name: Run Tests
run: dart run test --run-skipped -t e2e
pana:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2.3.4
- uses: subosito/flutter-action@v1.5.3
- name: Install Dependencies
run: |
dart pub get
dart pub global activate pana
- name: Verify Pub Score
run: |
PANA=$(pana . --no-warning); PANA_SCORE=$(echo $PANA | sed -n "s/.*Points: \([0-9]*\)\/\([0-9]*\)./\1\/\2/p")
echo "score: $PANA_SCORE"
IFS='/'; read -a SCORE_ARR <<< "$PANA_SCORE"; SCORE=SCORE_ARR[0]; TOTAL=SCORE_ARR[1]
if (( $SCORE < $TOTAL )); then echo "minimum score not met!"; exit 1; fi