Skip to content

Commit 35745a7

Browse files
committed
Merge remote-tracking branch 'google/master' into google#780
2 parents 8c1a3bd + 81d7abc commit 35745a7

20 files changed

+321
-56
lines changed

.github/workflows/dart.yml

+252-9
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Created with package:mono_repo v3.4.5
1+
# Created with package:mono_repo v3.4.6
22
name: Dart CI
33
on:
44
push:
@@ -33,11 +33,95 @@ jobs:
3333
- id: checkout
3434
uses: actions/checkout@v2
3535
- name: mono_repo self validate
36-
run: pub global activate mono_repo 3.4.5
36+
run: pub global activate mono_repo 3.4.6
3737
- name: mono_repo self validate
3838
run: pub global run mono_repo generate --validate
3939
job_002:
40-
name: "analyzer_and_format; PKGS: _test_yaml, checked_yaml, example, json_annotation, json_serializable; `dartfmt -n --set-exit-if-changed .`, `dartanalyzer --fatal-infos .`"
40+
name: "analyzer_and_format; Dart beta; PKGS: _test_yaml, checked_yaml, example, json_annotation, json_serializable; `dartfmt -n --set-exit-if-changed .`, `dartanalyzer --fatal-infos .`"
41+
runs-on: ubuntu-latest
42+
steps:
43+
- name: Cache Pub hosted dependencies
44+
uses: actions/cache@v2
45+
with:
46+
path: "~/.pub-cache/hosted"
47+
key: "os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_annotation-json_serializable;commands:dartfmt-dartanalyzer"
48+
restore-keys: |
49+
os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_annotation-json_serializable
50+
os:ubuntu-latest;pub-cache-hosted;dart:beta
51+
os:ubuntu-latest;pub-cache-hosted
52+
os:ubuntu-latest
53+
- uses: dart-lang/[email protected]
54+
with:
55+
sdk: beta
56+
- id: checkout
57+
uses: actions/checkout@v2
58+
- id: _test_yaml_pub_upgrade
59+
name: "_test_yaml; pub upgrade --no-precompile"
60+
if: "always() && steps.checkout.conclusion == 'success'"
61+
working-directory: _test_yaml
62+
run: pub upgrade --no-precompile
63+
- name: "_test_yaml; dartfmt -n --set-exit-if-changed ."
64+
if: "always() && steps._test_yaml_pub_upgrade.conclusion == 'success'"
65+
working-directory: _test_yaml
66+
run: dartfmt -n --set-exit-if-changed .
67+
- name: "_test_yaml; dartanalyzer --fatal-infos ."
68+
if: "always() && steps._test_yaml_pub_upgrade.conclusion == 'success'"
69+
working-directory: _test_yaml
70+
run: dartanalyzer --fatal-infos .
71+
- id: checked_yaml_pub_upgrade
72+
name: "checked_yaml; pub upgrade --no-precompile"
73+
if: "always() && steps.checkout.conclusion == 'success'"
74+
working-directory: checked_yaml
75+
run: pub upgrade --no-precompile
76+
- name: "checked_yaml; dartfmt -n --set-exit-if-changed ."
77+
if: "always() && steps.checked_yaml_pub_upgrade.conclusion == 'success'"
78+
working-directory: checked_yaml
79+
run: dartfmt -n --set-exit-if-changed .
80+
- name: "checked_yaml; dartanalyzer --fatal-infos ."
81+
if: "always() && steps.checked_yaml_pub_upgrade.conclusion == 'success'"
82+
working-directory: checked_yaml
83+
run: dartanalyzer --fatal-infos .
84+
- id: example_pub_upgrade
85+
name: "example; pub upgrade --no-precompile"
86+
if: "always() && steps.checkout.conclusion == 'success'"
87+
working-directory: example
88+
run: pub upgrade --no-precompile
89+
- name: "example; dartfmt -n --set-exit-if-changed ."
90+
if: "always() && steps.example_pub_upgrade.conclusion == 'success'"
91+
working-directory: example
92+
run: dartfmt -n --set-exit-if-changed .
93+
- name: "example; dartanalyzer --fatal-infos ."
94+
if: "always() && steps.example_pub_upgrade.conclusion == 'success'"
95+
working-directory: example
96+
run: dartanalyzer --fatal-infos .
97+
- id: json_annotation_pub_upgrade
98+
name: "json_annotation; pub upgrade --no-precompile"
99+
if: "always() && steps.checkout.conclusion == 'success'"
100+
working-directory: json_annotation
101+
run: pub upgrade --no-precompile
102+
- name: "json_annotation; dartfmt -n --set-exit-if-changed ."
103+
if: "always() && steps.json_annotation_pub_upgrade.conclusion == 'success'"
104+
working-directory: json_annotation
105+
run: dartfmt -n --set-exit-if-changed .
106+
- name: "json_annotation; dartanalyzer --fatal-infos ."
107+
if: "always() && steps.json_annotation_pub_upgrade.conclusion == 'success'"
108+
working-directory: json_annotation
109+
run: dartanalyzer --fatal-infos .
110+
- id: json_serializable_pub_upgrade
111+
name: "json_serializable; pub upgrade --no-precompile"
112+
if: "always() && steps.checkout.conclusion == 'success'"
113+
working-directory: json_serializable
114+
run: pub upgrade --no-precompile
115+
- name: "json_serializable; dartfmt -n --set-exit-if-changed ."
116+
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
117+
working-directory: json_serializable
118+
run: dartfmt -n --set-exit-if-changed .
119+
- name: "json_serializable; dartanalyzer --fatal-infos ."
120+
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
121+
working-directory: json_serializable
122+
run: dartanalyzer --fatal-infos .
123+
job_003:
124+
name: "analyzer_and_format; Dart dev; PKGS: _test_yaml, checked_yaml, example, json_annotation, json_serializable; `dartfmt -n --set-exit-if-changed .`, `dartanalyzer --fatal-infos .`"
41125
runs-on: ubuntu-latest
42126
steps:
43127
- name: Cache Pub hosted dependencies
@@ -120,8 +204,67 @@ jobs:
120204
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
121205
working-directory: json_serializable
122206
run: dartanalyzer --fatal-infos .
123-
job_003:
124-
name: "unit_test; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test`"
207+
job_004:
208+
name: "unit_test; Dart beta; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test`"
209+
runs-on: ubuntu-latest
210+
steps:
211+
- name: Cache Pub hosted dependencies
212+
uses: actions/cache@v2
213+
with:
214+
path: "~/.pub-cache/hosted"
215+
key: "os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_serializable;commands:test_0"
216+
restore-keys: |
217+
os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_serializable
218+
os:ubuntu-latest;pub-cache-hosted;dart:beta
219+
os:ubuntu-latest;pub-cache-hosted
220+
os:ubuntu-latest
221+
- uses: dart-lang/[email protected]
222+
with:
223+
sdk: beta
224+
- id: checkout
225+
uses: actions/checkout@v2
226+
- id: _test_yaml_pub_upgrade
227+
name: "_test_yaml; pub upgrade --no-precompile"
228+
if: "always() && steps.checkout.conclusion == 'success'"
229+
working-directory: _test_yaml
230+
run: pub upgrade --no-precompile
231+
- name: _test_yaml; pub run test
232+
if: "always() && steps._test_yaml_pub_upgrade.conclusion == 'success'"
233+
working-directory: _test_yaml
234+
run: pub run test
235+
- id: checked_yaml_pub_upgrade
236+
name: "checked_yaml; pub upgrade --no-precompile"
237+
if: "always() && steps.checkout.conclusion == 'success'"
238+
working-directory: checked_yaml
239+
run: pub upgrade --no-precompile
240+
- name: checked_yaml; pub run test
241+
if: "always() && steps.checked_yaml_pub_upgrade.conclusion == 'success'"
242+
working-directory: checked_yaml
243+
run: pub run test
244+
- id: example_pub_upgrade
245+
name: "example; pub upgrade --no-precompile"
246+
if: "always() && steps.checkout.conclusion == 'success'"
247+
working-directory: example
248+
run: pub upgrade --no-precompile
249+
- name: example; pub run test
250+
if: "always() && steps.example_pub_upgrade.conclusion == 'success'"
251+
working-directory: example
252+
run: pub run test
253+
- id: json_serializable_pub_upgrade
254+
name: "json_serializable; pub upgrade --no-precompile"
255+
if: "always() && steps.checkout.conclusion == 'success'"
256+
working-directory: json_serializable
257+
run: pub upgrade --no-precompile
258+
- name: json_serializable; pub run test
259+
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
260+
working-directory: json_serializable
261+
run: pub run test
262+
needs:
263+
- job_001
264+
- job_002
265+
- job_003
266+
job_005:
267+
name: "unit_test; Dart dev; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test`"
125268
runs-on: ubuntu-latest
126269
steps:
127270
- name: Cache Pub hosted dependencies
@@ -178,8 +321,41 @@ jobs:
178321
needs:
179322
- job_001
180323
- job_002
181-
job_004:
182-
name: "unit_test; PKG: json_serializable; `pub run test -p chrome`"
324+
- job_003
325+
job_006:
326+
name: "unit_test; Dart beta; PKG: json_serializable; `pub run test -p chrome`"
327+
runs-on: ubuntu-latest
328+
steps:
329+
- name: Cache Pub hosted dependencies
330+
uses: actions/cache@v2
331+
with:
332+
path: "~/.pub-cache/hosted"
333+
key: "os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:json_serializable;commands:test_2"
334+
restore-keys: |
335+
os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:json_serializable
336+
os:ubuntu-latest;pub-cache-hosted;dart:beta
337+
os:ubuntu-latest;pub-cache-hosted
338+
os:ubuntu-latest
339+
- uses: dart-lang/[email protected]
340+
with:
341+
sdk: beta
342+
- id: checkout
343+
uses: actions/checkout@v2
344+
- id: json_serializable_pub_upgrade
345+
name: "json_serializable; pub upgrade --no-precompile"
346+
if: "always() && steps.checkout.conclusion == 'success'"
347+
working-directory: json_serializable
348+
run: pub upgrade --no-precompile
349+
- name: "json_serializable; pub run test -p chrome"
350+
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
351+
working-directory: json_serializable
352+
run: pub run test -p chrome
353+
needs:
354+
- job_001
355+
- job_002
356+
- job_003
357+
job_007:
358+
name: "unit_test; Dart dev; PKG: json_serializable; `pub run test -p chrome`"
183359
runs-on: ubuntu-latest
184360
steps:
185361
- name: Cache Pub hosted dependencies
@@ -209,8 +385,72 @@ jobs:
209385
needs:
210386
- job_001
211387
- job_002
212-
job_005:
213-
name: "ensure_build; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart`"
388+
- job_003
389+
job_008:
390+
name: "ensure_build; Dart beta; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart`"
391+
runs-on: ubuntu-latest
392+
steps:
393+
- name: Cache Pub hosted dependencies
394+
uses: actions/cache@v2
395+
with:
396+
path: "~/.pub-cache/hosted"
397+
key: "os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_serializable;commands:test_1"
398+
restore-keys: |
399+
os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_serializable
400+
os:ubuntu-latest;pub-cache-hosted;dart:beta
401+
os:ubuntu-latest;pub-cache-hosted
402+
os:ubuntu-latest
403+
- uses: dart-lang/[email protected]
404+
with:
405+
sdk: beta
406+
- id: checkout
407+
uses: actions/checkout@v2
408+
- id: _test_yaml_pub_upgrade
409+
name: "_test_yaml; pub upgrade --no-precompile"
410+
if: "always() && steps.checkout.conclusion == 'success'"
411+
working-directory: _test_yaml
412+
run: pub upgrade --no-precompile
413+
- name: "_test_yaml; pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart"
414+
if: "always() && steps._test_yaml_pub_upgrade.conclusion == 'success'"
415+
working-directory: _test_yaml
416+
run: pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart
417+
- id: checked_yaml_pub_upgrade
418+
name: "checked_yaml; pub upgrade --no-precompile"
419+
if: "always() && steps.checkout.conclusion == 'success'"
420+
working-directory: checked_yaml
421+
run: pub upgrade --no-precompile
422+
- name: "checked_yaml; pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart"
423+
if: "always() && steps.checked_yaml_pub_upgrade.conclusion == 'success'"
424+
working-directory: checked_yaml
425+
run: pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart
426+
- id: example_pub_upgrade
427+
name: "example; pub upgrade --no-precompile"
428+
if: "always() && steps.checkout.conclusion == 'success'"
429+
working-directory: example
430+
run: pub upgrade --no-precompile
431+
- name: "example; pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart"
432+
if: "always() && steps.example_pub_upgrade.conclusion == 'success'"
433+
working-directory: example
434+
run: pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart
435+
- id: json_serializable_pub_upgrade
436+
name: "json_serializable; pub upgrade --no-precompile"
437+
if: "always() && steps.checkout.conclusion == 'success'"
438+
working-directory: json_serializable
439+
run: pub upgrade --no-precompile
440+
- name: "json_serializable; pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart"
441+
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
442+
working-directory: json_serializable
443+
run: pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart
444+
needs:
445+
- job_001
446+
- job_002
447+
- job_003
448+
- job_004
449+
- job_005
450+
- job_006
451+
- job_007
452+
job_009:
453+
name: "ensure_build; Dart dev; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart`"
214454
runs-on: ubuntu-latest
215455
steps:
216456
- name: Cache Pub hosted dependencies
@@ -269,3 +509,6 @@ jobs:
269509
- job_002
270510
- job_003
271511
- job_004
512+
- job_005
513+
- job_006
514+
- job_007

_test_yaml/mono_pkg.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# See https://github.com/google/mono_repo.dart for details on this file
22
dart:
3+
- beta # change this to 1.12.0 when it's released!
34
- dev
45

56
stages:

_test_yaml/pubspec.yaml

+1-3
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ dev_dependencies:
1111
json_annotation: any
1212
json_serializable: any
1313
test: ^1.6.0
14+
yaml: ^3.0.0
1415

1516
dependency_overrides:
1617
checked_yaml:
@@ -19,6 +20,3 @@ dependency_overrides:
1920
path: ../json_annotation
2021
json_serializable:
2122
path: ../json_serializable
22-
23-
# For yaml!
24-
yaml: 3.0.0-nullsafety.0

checked_yaml/CHANGELOG.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## 2.0.0-nullsafety-dev
1+
## 2.0.0-dev
22

33
- *BREAKING* `checkedYamlDecode` `sourceUrl` parameter is now a `Uri`.
44
- Require at least Dart `2.12.0-0`.

checked_yaml/mono_pkg.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# See https://github.com/google/mono_repo.dart for details on this file
22
dart:
3+
- beta # change this to 1.12.0 when it's released!
34
- dev
45

56
stages:

checked_yaml/pubspec.yaml

+4-7
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: checked_yaml
2-
version: 1.9.0-nullsafety-dev
2+
version: 1.9.0-dev
33

44
description: >-
55
Generate more helpful exceptions when decoding YAML documents using
@@ -10,22 +10,19 @@ environment:
1010

1111
dependencies:
1212
json_annotation: '>=2.2.0 <5.0.0'
13-
source_span: ^1.8.0-nullsafety.4
14-
yaml: ^3.0.0-nullsafety.0
13+
source_span: ^1.8.0
14+
yaml: ^3.0.0
1515

1616
dev_dependencies:
1717
build_runner: ^1.0.0
1818
build_verify: ^1.1.0
1919
json_serializable: ^3.0.0
2020
path: ^1.0.0
21-
test: ^1.16.0-nullsafety.7
21+
test: ^1.16.0
2222
test_process: ^1.0.1
2323

2424
dependency_overrides:
2525
json_annotation:
2626
path: ../json_annotation
2727
json_serializable:
2828
path: ../json_serializable
29-
# Need to force yaml for now due to dev dependencies
30-
# build_runner -> build_config -> pubspec_parse
31-
yaml: 3.0.0-nullsafety.0

example/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ dependencies to your `pubspec.yaml`.
55

66
```yaml
77
dependencies:
8-
json_annotation: ^3.0.0
8+
json_annotation: ^4.0.0
99

1010
dev_dependencies:
1111
build_runner: ^1.0.0
12-
json_serializable: ^3.2.0
12+
json_serializable: ^4.0.0
1313
```
1414
1515
Annotate your code with classes defined in

example/mono_pkg.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# See https://github.com/google/mono_repo.dart for details on this file
22
dart:
3+
- beta # change this to 1.12.0 when it's released!
34
- dev
45

56
stages:

0 commit comments

Comments
 (0)