Unverified Commit 57cda51f authored by godofredoc's avatar godofredoc Committed by GitHub

Fix gradle_plugin_light_apk test. (#66496)

parent faa4b663
......@@ -8,6 +8,9 @@ import 'package:path/path.dart' as path;
import 'package:flutter_devicelab/framework/framework.dart';
import 'package:flutter_devicelab/framework/utils.dart';
final String platformLineSep = Platform.isWindows ? '\r\n' : '\n';
final List<String> flutterAssets = <String>[
'assets/flutter_assets/AssetManifest.json',
'assets/flutter_assets/NOTICES',
......@@ -267,8 +270,8 @@ subprojects {
final File pubspec = File(path.join(rootPath, 'pubspec.yaml'));
String content = await pubspec.readAsString();
content = content.replaceFirst(
'\ndependencies:\n',
'\ndependencies:\n $plugin:\n',
'${platformLineSep}dependencies:$platformLineSep',
'${platformLineSep}dependencies:$platformLineSep $plugin:$platformLineSep',
);
await pubspec.writeAsString(content, flush: true);
}
......@@ -315,7 +318,7 @@ android {
path.join(parent.path, 'hello', 'pubspec.yaml')
);
final String contents = pubspec.readAsStringSync();
final String newContents = contents.replaceFirst('# The following section is specific to Flutter.\nflutter:\n', '''
final String newContents = contents.replaceFirst('# The following section is specific to Flutter.${platformLineSep}flutter:$platformLineSep', '''
flutter:
assets:
- lib/gallery/example_code.dart
......
......@@ -357,6 +357,13 @@
"enabled":true,
"run_if":["dev/**", "bin/**"]
},
{
"name": "Windows gradle_plugin_light_apk_test",
"repo": "flutter",
"task_name": "win_gradle_plugin_light_apk_test",
"enabled":true,
"run_if":["dev/**", "bin/**"]
},
{
"name": "Windows gradle_r8_test",
"repo": "flutter",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment