-
Notifications
You must be signed in to change notification settings - Fork 0
80 lines (68 loc) · 2.18 KB
/
Copy pathtest.yml
File metadata and controls
80 lines (68 loc) · 2.18 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
name: Tests
on:
workflow_dispatch:
push:
branches:
- main
pull_request:
types: [opened, synchronize, reopened]
merge_group:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
# The declared floor (Flutter 3.27) isn't run here — dev tooling (melos, flutter_lints)
# needs a newer SDK. It's validated by the dry-run + pana jobs instead.
jobs:
test:
name: Unit Tests (${{ matrix.id }})
runs-on: ubuntu-latest
timeout-minutes: 20
continue-on-error: ${{ matrix.experimental }}
strategy:
fail-fast: false
matrix:
include:
# Pinned dev SDK (.fvmrc) — the gate.
- id: pinned
channel: stable
flutter-version-file: .fvmrc
deps-target: deps-lockfile
experimental: false
# Latest beta — non-blocking forward canary.
- id: beta
channel: beta
flutter-version-file: ""
deps-target: deps
experimental: true
steps:
- name: Harden the runner
uses: step-security/harden-runner@9af89fc71515a100421586dfdb3dc9c984fbf411 # v2.19.4
with:
egress-policy: audit
- name: Checkout code
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
persist-credentials: false
- name: Set up Flutter
uses: subosito/flutter-action@1a449444c387b1966244ae4d4f8c696479add0b2 # v2.23.0
with:
channel: ${{ matrix.channel }}
flutter-version-file: ${{ matrix.flutter-version-file }}
cache: true
- name: Install dependencies
env:
DEPS_TARGET: ${{ matrix.deps-target }}
run: make "$DEPS_TARGET"
- name: Run SDK package tests
run: make test-sdk-machine
- name: Run playground app tests
run: make test-playground
- name: Upload test reports
if: failure()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: flutter-test-reports-${{ matrix.id }}
path: test-results/
if-no-files-found: ignore