-
-
Notifications
You must be signed in to change notification settings - Fork 236
117 lines (105 loc) · 3.47 KB
/
sqflite.yml
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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
name: sentry-sqflite
on:
push:
branches:
- main
- release/**
pull_request:
paths:
- "!**/*.md"
- "!**/class-diagram.svg"
- ".github/workflows/logging.yml"
- "dart/**"
- "sqflite/**"
jobs:
cancel-previous-workflow:
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@85880fa0301c86cca9da44039ee3bb12d3bedbfa # [email protected]
with:
access_token: ${{ github.token }}
build:
name: ${{ matrix.target }} | ${{ matrix.os }} | ${{ matrix.sdk }}
runs-on: ${{ matrix.os }}
timeout-minutes: 30
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
target: ["ios", "android", "macos", "linux", "windows"]
sdk: ["stable", "beta"]
exclude:
- os: ubuntu-latest
target: ios
- os: ubuntu-latest
target: macos
- os: ubuntu-latest
target: windows
- os: windows-latest
target: ios
- os: windows-latest
target: android
- os: windows-latest
target: macos
- os: windows-latest
target: linux
# macos-latest is taking hours due to limited resources
- os: macos-latest
target: android
- os: macos-latest
target: linux
- os: macos-latest
target: windows
# Bad CPU type in executable
- os: macos-latest
sdk: beta
# Exclude beta for windows for now until the flutter set up action does not fail anymore
- os: windows-latest
sdk: beta
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
if: ${{ matrix.target == 'android' }}
with:
java-version: "11"
distribution: "adopt"
# Install required dependencies for Flutter on Linux on Ubuntu
- name: "Setup Linux"
run: |
sudo apt update
sudo apt install -y cmake dbus libblkid-dev libgtk-3-dev liblzma-dev ninja-build pkg-config xvfb
sudo apt install -y network-manager upower
if: matrix.os == 'ubuntu-latest' && matrix.target == 'linux'
- uses: subosito/flutter-action@44ac965b96f18d999802d4b807e3256d5a3f9fa1 # [email protected]
with:
channel: ${{ matrix.sdk }}
- run: flutter upgrade
- name: Pub Get
run: |
cd sqflite
flutter pub get
- name: Test VM with coverage
run: |
cd sqflite
flutter test --coverage --test-randomize-ordering-seed=random
- uses: codecov/codecov-action@b9fd7d16f6d7d1b5d2bec1a2887e65ceed900238 # pin@v3
if: runner.os == 'Linux' && matrix.sdk == 'stable' && matrix.target == 'linux'
with:
name: sentry_sqflite
file: ./sqflite/coverage/lcov.info
functionalities: "search" # remove after https://github.com/codecov/codecov-action/issues/600
token: ${{ secrets.CODECOV_TOKEN }}
- uses: VeryGoodOpenSource/very_good_coverage@c953fca3e24a915e111cc6f55f03f756dcb3964c # [email protected]
if: runner.os == 'Linux' && matrix.sdk == 'stable' && matrix.target == 'linux'
with:
path: "./sqflite/coverage/lcov.info"
min_coverage: 80
analyze:
uses: ./.github/workflows/analyze.yml
with:
package: sqflite
sdk: flutter