Skip to content

Commit

Permalink
[google_maps_flutter] Fix prefer_const_literals_to_create_immutables (f…
Browse files Browse the repository at this point in the history
  • Loading branch information
jmagman authored and yutaaraki-toydium committed Jun 4, 2022
1 parent 3aabb0d commit 15bde36
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 16 deletions.
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## NEXT

* Adds `const` constructor parameters in example tests.

## 0.3.3

* Removes custom `analysis_options.yaml` (and fixes code to comply with newest rules).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,8 @@ void main() {
expect(() {
controller.updateCircles(
CircleUpdates.from(
<Circle>{},
<Circle>{},
const <Circle>{},
const <Circle>{},
),
);
}, throwsAssertionError);
Expand All @@ -159,8 +159,8 @@ void main() {
expect(() {
controller.updatePolygons(
PolygonUpdates.from(
<Polygon>{},
<Polygon>{},
const <Polygon>{},
const <Polygon>{},
),
);
}, throwsAssertionError);
Expand All @@ -173,8 +173,8 @@ void main() {
expect(() {
controller.updatePolylines(
PolylineUpdates.from(
<Polyline>{},
<Polyline>{},
const <Polyline>{},
const <Polyline>{},
),
);
}, throwsAssertionError);
Expand All @@ -187,8 +187,8 @@ void main() {
expect(() {
controller.updateMarkers(
MarkerUpdates.from(
<Marker>{},
<Marker>{},
const <Marker>{},
const <Marker>{},
),
);
}, throwsAssertionError);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -233,8 +233,8 @@ void main() {
// Geometry
testWidgets('updateMarkers', (WidgetTester tester) async {
final MarkerUpdates expectedUpdates = MarkerUpdates.from(
<Marker>{},
<Marker>{},
const <Marker>{},
const <Marker>{},
);

await plugin.updateMarkers(expectedUpdates, mapId: mapId);
Expand All @@ -243,8 +243,8 @@ void main() {
});
testWidgets('updatePolygons', (WidgetTester tester) async {
final PolygonUpdates expectedUpdates = PolygonUpdates.from(
<Polygon>{},
<Polygon>{},
const <Polygon>{},
const <Polygon>{},
);

await plugin.updatePolygons(expectedUpdates, mapId: mapId);
Expand All @@ -253,8 +253,8 @@ void main() {
});
testWidgets('updatePolylines', (WidgetTester tester) async {
final PolylineUpdates expectedUpdates = PolylineUpdates.from(
<Polyline>{},
<Polyline>{},
const <Polyline>{},
const <Polyline>{},
);

await plugin.updatePolylines(expectedUpdates, mapId: mapId);
Expand All @@ -263,8 +263,8 @@ void main() {
});
testWidgets('updateCircles', (WidgetTester tester) async {
final CircleUpdates expectedUpdates = CircleUpdates.from(
<Circle>{},
<Circle>{},
const <Circle>{},
const <Circle>{},
);

await plugin.updateCircles(expectedUpdates, mapId: mapId);
Expand Down

0 comments on commit 15bde36

Please sign in to comment.