Skip to content

Commit c659b90

Browse files
committed
prepare for release
1 parent 02b57ff commit c659b90

File tree

3 files changed

+5
-9
lines changed

3 files changed

+5
-9
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 0.5.1+7
2+
3+
* Generate valid strong-mode code for typed lists.
4+
15
## 0.5.1+6
26

37
* Support the latest version of `pkg/build`.

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: source_gen
2-
version: 0.5.2-dev
2+
version: 0.5.1+7
33
author: Dart Team <[email protected]>
44
description: Automatic sourcecode generation for Dart
55
homepage: https://github.com/dart-lang/source_gen

test/json_serializable_test.dart

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -77,17 +77,13 @@ void main() {
7777
var element = await _getClassForCodeString('ParentObject');
7878
var output = await _generator.generate(element, null);
7979

80-
expect(output, isNotNull);
81-
8280
expect(output, contains('new ChildObject.fromJson'));
8381
});
8482

8583
test('class with child list of json-able objects', () async {
8684
var element = await _getClassForCodeString('ParentObjectWithChildren');
8785
var output = await _generator.generate(element, null);
8886

89-
expect(output, isNotNull);
90-
9187
expect(output, contains('.toList()'));
9288
expect(output, contains('new ChildObject.fromJson'));
9389
});
@@ -97,17 +93,13 @@ void main() {
9793
await _getClassForCodeString('ParentObjectWithDynamicChildren');
9894
var output = await _generator.generate(element, null);
9995

100-
expect(output, isNotNull);
101-
10296
expect(output, contains('(json[\'children\'] as List)?.map('));
10397
});
10498

10599
test('class with list of int is cast for strong mode', () async {
106100
var element = await _getClassForCodeString('Person');
107101
var output = await _generator.generate(element, null);
108102

109-
expect(output, isNotNull);
110-
111103
expect(output,
112104
contains("json['listOfInts'] as List)?.map((v0) => v0 as int)"));
113105
});

0 commit comments

Comments
 (0)