diff --git a/dev/bots/test.dart b/dev/bots/test.dart index a8d3bb00e0..4a3948d9ae 100644 --- a/dev/bots/test.dart +++ b/dev/bots/test.dart @@ -544,24 +544,27 @@ Future _runAddToAppLifeCycleTests() async { Future _runFrameworkTests() async { final bq.BigqueryApi bigqueryApi = await _getBigqueryApi(); + final List nullSafetyOptions = ['--enable-experiment=non-nullable', '--no-sound-null-safety']; + final List trackWidgetCreationAlternatives = ['--track-widget-creation', '--no-track-widget-creation']; Future runWidgets() async { print('${green}Running packages/flutter tests for$reset: ${cyan}test/widgets/$reset'); - await _runFlutterTest( - path.join(flutterRoot, 'packages', 'flutter'), - options: ['--track-widget-creation'], - tableData: bigqueryApi?.tabledata, - tests: [ path.join('test', 'widgets') + path.separator ], - ); - await _runFlutterTest( - path.join(flutterRoot, 'packages', 'flutter'), - options: ['--no-track-widget-creation'], - tableData: bigqueryApi?.tabledata, - tests: [ path.join('test', 'widgets') + path.separator ], - ); + for (final String trackWidgetCreationOption in trackWidgetCreationAlternatives) { + await _runFlutterTest( + path.join(flutterRoot, 'packages', 'flutter'), + options: [trackWidgetCreationOption, ...nullSafetyOptions], + tableData: bigqueryApi?.tabledata, + tests: [ path.join('test', 'widgets') + path.separator ], + ); + } // Try compiling code outside of the packages/flutter directory with and without --track-widget-creation - await _runFlutterTest(path.join(flutterRoot, 'dev', 'integration_tests', 'flutter_gallery'), options: ['--track-widget-creation'], tableData: bigqueryApi?.tabledata); - await _runFlutterTest(path.join(flutterRoot, 'dev', 'integration_tests', 'flutter_gallery'), options: ['--no-track-widget-creation'], tableData: bigqueryApi?.tabledata); + for (final String trackWidgetCreationOption in trackWidgetCreationAlternatives) { + await _runFlutterTest( + path.join(flutterRoot, 'dev', 'integration_tests', 'flutter_gallery'), + options: [trackWidgetCreationOption], + tableData: bigqueryApi?.tabledata, + ); + } } Future runLibraries() async { @@ -572,18 +575,14 @@ Future _runFrameworkTests() async { .map((Directory dir) => path.join('test', path.basename(dir.path)) + path.separator) .toList(); print('${green}Running packages/flutter tests$reset for: $cyan${tests.join(", ")}$reset'); - await _runFlutterTest( - path.join(flutterRoot, 'packages', 'flutter'), - options: ['--track-widget-creation'], - tableData: bigqueryApi?.tabledata, - tests: tests, - ); - await _runFlutterTest( - path.join(flutterRoot, 'packages', 'flutter'), - options: ['--no-track-widget-creation'], - tableData: bigqueryApi?.tabledata, - tests: tests, - ); + for (final String trackWidgetCreationOption in trackWidgetCreationAlternatives) { + await _runFlutterTest( + path.join(flutterRoot, 'packages', 'flutter'), + options: [trackWidgetCreationOption, ...nullSafetyOptions], + tableData: bigqueryApi?.tabledata, + tests: tests, + ); + } } Future runMisc() async { @@ -604,9 +603,7 @@ Future _runFrameworkTests() async { await _runFlutterTest(path.join(flutterRoot, 'packages', 'flutter_localizations'), tableData: bigqueryApi?.tabledata); await _runFlutterTest(path.join(flutterRoot, 'packages', 'flutter_test'), tableData: bigqueryApi?.tabledata); await _runFlutterTest(path.join(flutterRoot, 'packages', 'fuchsia_remote_debug_protocol'), tableData: bigqueryApi?.tabledata); - await _runFlutterTest(path.join(flutterRoot, 'dev', 'integration_tests', 'non_nullable'), - options: ['--enable-experiment=non-nullable', '--no-sound-null-safety'], - ); + await _runFlutterTest(path.join(flutterRoot, 'dev', 'integration_tests', 'non_nullable'), options: nullSafetyOptions); await _runFlutterTest( path.join(flutterRoot, 'dev', 'tracing_tests'), options: ['--enable-vmservice'], diff --git a/examples/layers/rendering/custom_coordinate_systems.dart b/examples/layers/rendering/custom_coordinate_systems.dart index 5d329f8c3b..5307b567f4 100644 --- a/examples/layers/rendering/custom_coordinate_systems.dart +++ b/examples/layers/rendering/custom_coordinate_systems.dart @@ -2,6 +2,8 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. +// @dart = 2.8 + // This example shows how to build a render tree with a non-cartesian coordinate // system. Most of the guts of this examples are in src/sector_layout.dart. diff --git a/examples/layers/rendering/src/sector_layout.dart b/examples/layers/rendering/src/sector_layout.dart index 825934ac6c..6cb2d3c55d 100644 --- a/examples/layers/rendering/src/sector_layout.dart +++ b/examples/layers/rendering/src/sector_layout.dart @@ -2,6 +2,8 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. +// @dart = 2.8 + import 'dart:math' as math; import 'package:flutter/rendering.dart'; diff --git a/packages/flutter/pubspec.yaml b/packages/flutter/pubspec.yaml index 4f8ecdead5..8ace99fce5 100644 --- a/packages/flutter/pubspec.yaml +++ b/packages/flutter/pubspec.yaml @@ -5,7 +5,7 @@ homepage: http://flutter.dev environment: # The pub client defaults to an <2.0.0 sdk constraint which we need to explicitly overwrite. - sdk: ">=2.2.2 <3.0.0" + sdk: ">=2.9.0-14.0.dev <3.0.0" dependencies: # To update these, use "flutter update-packages --force-upgrade".