diff --git a/dev/devicelab/lib/tasks/integration_tests.dart b/dev/devicelab/lib/tasks/integration_tests.dart index 528118be089..984ec7bfa1d 100644 --- a/dev/devicelab/lib/tasks/integration_tests.dart +++ b/dev/devicelab/lib/tasks/integration_tests.dart @@ -78,13 +78,6 @@ TaskFunction createCodegenerationIntegrationTest() { ); } -TaskFunction createImageLoadingIntegrationTest() { - return DriverTest( - '${flutterDirectory.path}/dev/integration_tests/image_loading', - 'lib/main.dart', - ); -} - TaskFunction createAndroidSplashScreenKitchenSinkTest() { return DriverTest( '${flutterDirectory.path}/dev/integration_tests/android_splash_screens/splash_screen_kitchen_sink', diff --git a/dev/integration_tests/image_loading/android/app/bin/build.gradle b/dev/integration_tests/image_loading/android/app/bin/build.gradle deleted file mode 100644 index a2f4fa827e4..00000000000 --- a/dev/integration_tests/image_loading/android/app/bin/build.gradle +++ /dev/null @@ -1,50 +0,0 @@ -// Copyright 2014 The Flutter Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -def localProperties = new Properties() -def localPropertiesFile = rootProject.file('local.properties') -if (localPropertiesFile.exists()) { - localPropertiesFile.withInputStream { stream -> - localProperties.load(stream) - } -} - -def flutterRoot = localProperties.getProperty('flutter.sdk') -if (flutterRoot == null) { - throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") -} - -apply plugin: 'com.android.application' -apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" - -android { - compileSdkVersion 30 - - defaultConfig { - minSdkVersion 16 - targetSdkVersion 30 - versionCode 1 - versionName "0.0.1" - } - - buildTypes { - release { - // TODO: Add your own signing config for the release build. - // Signing with the debug keys for now, so `flutter run --release` works. - signingConfig signingConfigs.debug - } - } - - aaptOptions { - // TODO(goderbauer): remove when https://github.com/flutter/flutter/issues/8986 is resolved. - if(System.getenv("FLUTTER_CI_WIN")) { - println "AAPT cruncher disabled when running on Win CI." - cruncherEnabled false - } - } -} - -flutter { - source '../..' -} diff --git a/dev/integration_tests/image_loading/android/app/bin/src/main/AndroidManifest.xml b/dev/integration_tests/image_loading/android/app/bin/src/main/AndroidManifest.xml deleted file mode 100644 index 3002b1b3517..00000000000 --- a/dev/integration_tests/image_loading/android/app/bin/src/main/AndroidManifest.xml +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - - - - - - - - - - - - diff --git a/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-hdpi/ic_launcher.png b/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-hdpi/ic_launcher.png deleted file mode 100644 index db77bb4b7b0..00000000000 Binary files a/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-hdpi/ic_launcher.png and /dev/null differ diff --git a/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-mdpi/ic_launcher.png b/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-mdpi/ic_launcher.png deleted file mode 100644 index 17987b79bb8..00000000000 Binary files a/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-mdpi/ic_launcher.png and /dev/null differ diff --git a/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-xhdpi/ic_launcher.png b/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-xhdpi/ic_launcher.png deleted file mode 100644 index 09d4391482b..00000000000 Binary files a/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-xhdpi/ic_launcher.png and /dev/null differ diff --git a/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-xxhdpi/ic_launcher.png b/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-xxhdpi/ic_launcher.png deleted file mode 100644 index d5f1c8d34e7..00000000000 Binary files a/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-xxhdpi/ic_launcher.png and /dev/null differ diff --git a/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-xxxhdpi/ic_launcher.png deleted file mode 100644 index 4d6372eebdb..00000000000 Binary files a/dev/integration_tests/image_loading/android/app/bin/src/main/res/mipmap-xxxhdpi/ic_launcher.png and /dev/null differ diff --git a/dev/integration_tests/image_loading/android/app/build.gradle b/dev/integration_tests/image_loading/android/app/build.gradle deleted file mode 100644 index a2f4fa827e4..00000000000 --- a/dev/integration_tests/image_loading/android/app/build.gradle +++ /dev/null @@ -1,50 +0,0 @@ -// Copyright 2014 The Flutter Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -def localProperties = new Properties() -def localPropertiesFile = rootProject.file('local.properties') -if (localPropertiesFile.exists()) { - localPropertiesFile.withInputStream { stream -> - localProperties.load(stream) - } -} - -def flutterRoot = localProperties.getProperty('flutter.sdk') -if (flutterRoot == null) { - throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") -} - -apply plugin: 'com.android.application' -apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" - -android { - compileSdkVersion 30 - - defaultConfig { - minSdkVersion 16 - targetSdkVersion 30 - versionCode 1 - versionName "0.0.1" - } - - buildTypes { - release { - // TODO: Add your own signing config for the release build. - // Signing with the debug keys for now, so `flutter run --release` works. - signingConfig signingConfigs.debug - } - } - - aaptOptions { - // TODO(goderbauer): remove when https://github.com/flutter/flutter/issues/8986 is resolved. - if(System.getenv("FLUTTER_CI_WIN")) { - println "AAPT cruncher disabled when running on Win CI." - cruncherEnabled false - } - } -} - -flutter { - source '../..' -} diff --git a/dev/integration_tests/image_loading/android/app/src/main/AndroidManifest.xml b/dev/integration_tests/image_loading/android/app/src/main/AndroidManifest.xml deleted file mode 100644 index 5ffd3d37eeb..00000000000 --- a/dev/integration_tests/image_loading/android/app/src/main/AndroidManifest.xml +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - - - - - - - - - - - - - diff --git a/dev/integration_tests/image_loading/android/app/src/main/java/com/yourcompany/platforminteraction/MainActivity.java b/dev/integration_tests/image_loading/android/app/src/main/java/com/yourcompany/platforminteraction/MainActivity.java deleted file mode 100644 index 19686c423b9..00000000000 --- a/dev/integration_tests/image_loading/android/app/src/main/java/com/yourcompany/platforminteraction/MainActivity.java +++ /dev/null @@ -1,10 +0,0 @@ -// Copyright 2014 The Flutter Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package com.yourcompany.platforminteraction; - -import io.flutter.embedding.android.FlutterActivity; - -public class MainActivity extends FlutterActivity { -} diff --git a/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-hdpi/ic_launcher.png deleted file mode 100644 index db77bb4b7b0..00000000000 Binary files a/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-hdpi/ic_launcher.png and /dev/null differ diff --git a/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-mdpi/ic_launcher.png deleted file mode 100644 index 17987b79bb8..00000000000 Binary files a/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-mdpi/ic_launcher.png and /dev/null differ diff --git a/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png deleted file mode 100644 index 09d4391482b..00000000000 Binary files a/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png and /dev/null differ diff --git a/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png deleted file mode 100644 index d5f1c8d34e7..00000000000 Binary files a/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png and /dev/null differ diff --git a/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png deleted file mode 100644 index 4d6372eebdb..00000000000 Binary files a/dev/integration_tests/image_loading/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png and /dev/null differ diff --git a/dev/integration_tests/image_loading/android/build.gradle b/dev/integration_tests/image_loading/android/build.gradle deleted file mode 100644 index c2c4160adfc..00000000000 --- a/dev/integration_tests/image_loading/android/build.gradle +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright 2014 The Flutter Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -buildscript { - repositories { - google() - jcenter() - } - - dependencies { - classpath 'com.android.tools.build:gradle:4.1.0' - } -} - -allprojects { - repositories { - google() - jcenter() - } -} - -rootProject.buildDir = '../build' -subprojects { - project.buildDir = "${rootProject.buildDir}/${project.name}" -} -subprojects { - project.evaluationDependsOn(':app') -} - -task clean(type: Delete) { - delete rootProject.buildDir -} diff --git a/dev/integration_tests/image_loading/android/gradle.properties b/dev/integration_tests/image_loading/android/gradle.properties deleted file mode 100644 index 94adc3a3f97..00000000000 --- a/dev/integration_tests/image_loading/android/gradle.properties +++ /dev/null @@ -1,3 +0,0 @@ -org.gradle.jvmargs=-Xmx1536M -android.useAndroidX=true -android.enableJetifier=true diff --git a/dev/integration_tests/image_loading/android/gradle/wrapper/gradle-wrapper.properties b/dev/integration_tests/image_loading/android/gradle/wrapper/gradle-wrapper.properties deleted file mode 100755 index bc6a58afdda..00000000000 --- a/dev/integration_tests/image_loading/android/gradle/wrapper/gradle-wrapper.properties +++ /dev/null @@ -1,6 +0,0 @@ -#Fri Jun 23 08:50:38 CEST 2017 -distributionBase=GRADLE_USER_HOME -distributionPath=wrapper/dists -zipStoreBase=GRADLE_USER_HOME -zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip diff --git a/dev/integration_tests/image_loading/android/settings.gradle b/dev/integration_tests/image_loading/android/settings.gradle deleted file mode 100644 index d3b6a4013d7..00000000000 --- a/dev/integration_tests/image_loading/android/settings.gradle +++ /dev/null @@ -1,15 +0,0 @@ -// Copyright 2014 The Flutter Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -include ':app' - -def localPropertiesFile = new File(rootProject.projectDir, "local.properties") -def properties = new Properties() - -assert localPropertiesFile.exists() -localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) } - -def flutterSdkPath = properties.getProperty("flutter.sdk") -assert flutterSdkPath != null, "flutter.sdk not set in local.properties" -apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle" diff --git a/dev/integration_tests/image_loading/lib/main.dart b/dev/integration_tests/image_loading/lib/main.dart deleted file mode 100644 index 1208eb1e528..00000000000 --- a/dev/integration_tests/image_loading/lib/main.dart +++ /dev/null @@ -1,77 +0,0 @@ -// Copyright 2014 The Flutter Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -import 'dart:async'; -import 'dart:io'; - -import 'package:flutter/material.dart'; -import 'package:mockito/mockito.dart'; - -void main() { - final ThrowingHttpClient httpClient = ThrowingHttpClient(); - final HttpOverrides overrides = ProvidedHttpOverrides(httpClient); - HttpOverrides.global = overrides; - final ZoneSpecification specification = ZoneSpecification( - handleUncaughtError:(Zone zone, ZoneDelegate delegate, Zone parent, Object error, StackTrace stackTrace) { - FlutterError.reportError(FlutterErrorDetails( - exception: error, - context: ErrorDescription('In the Zone handleUncaughtError handler'), - silent: false, - )); - }); - when(httpClient.getUrl(any)).thenAnswer((Invocation invocation) { - final Completer completer = Completer.sync(); - completer.completeError(Error()); - return completer.future; - }); - Zone.current.fork(specification: specification).run(() { - runApp(ImageLoader()); - }); -} - -class ImageLoader extends StatefulWidget { - @override - _ImageLoaderState createState() => _ImageLoaderState(); -} - -class _ImageLoaderState extends State { - bool caughtError = false; - - @override - void initState() { - // This is not an image, but we don't care since we're using a faked - // http client. - const NetworkImage image = NetworkImage('https://github.com/flutter/flutter'); - final ImageStream stream = image.resolve(ImageConfiguration.empty); - ImageStreamListener listener; - listener = ImageStreamListener( - (ImageInfo info, bool syncCall) { - stream.removeListener(listener); - }, - onError: (dynamic error, StackTrace stackTrace) { - print('ERROR caught by framework'); - stream.removeListener(listener); - }, - ); - stream.addListener(listener); - super.initState(); - } - - @override - Widget build(BuildContext context) { - return const Text('hello', textDirection: TextDirection.ltr); - } -} - -class ThrowingHttpClient extends Mock implements HttpClient {} - -class ProvidedHttpOverrides extends HttpOverrides { - ProvidedHttpOverrides(this.httpClient); - - final ThrowingHttpClient httpClient; - @override - HttpClient createHttpClient(SecurityContext context) { - return httpClient; - } -} diff --git a/dev/integration_tests/image_loading/pubspec.yaml b/dev/integration_tests/image_loading/pubspec.yaml deleted file mode 100644 index d6ea68076c3..00000000000 --- a/dev/integration_tests/image_loading/pubspec.yaml +++ /dev/null @@ -1,64 +0,0 @@ -name: image_loading -description: Integration testing library for Android semantics -environment: - sdk: '>=2.9.0 <3.0.0' - -dependencies: - flutter: - sdk: flutter - test: 1.16.3 - mockito: 4.1.1 - - _fe_analyzer_shared: 14.0.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - analyzer: 0.41.2 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - args: 1.6.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - async: 2.5.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - boolean_selector: 2.1.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - characters: 1.1.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - charcode: 1.2.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - cli_util: 0.3.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - collection: 1.15.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - convert: 3.0.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - coverage: 0.15.2 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - crypto: 3.0.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - file: 6.1.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - glob: 2.0.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - http_multi_server: 2.2.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - http_parser: 3.1.4 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - io: 0.3.4 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - js: 0.6.3 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - logging: 0.11.4 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - matcher: 0.12.10 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - meta: 1.3.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - mime: 1.0.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - node_preamble: 1.4.13 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - package_config: 1.9.3 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - path: 1.8.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - pedantic: 1.10.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - pool: 1.5.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - pub_semver: 1.4.4 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - shelf: 0.7.9 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - shelf_packages_handler: 2.0.1 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - shelf_static: 0.2.9+2 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - shelf_web_socket: 0.2.4+1 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - source_map_stack_trace: 2.1.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - source_maps: 0.10.10 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - source_span: 1.8.1 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - stack_trace: 1.10.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - stream_channel: 2.1.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - string_scanner: 1.1.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - term_glyph: 1.2.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - test_api: 0.2.19 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - test_core: 0.3.13 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - typed_data: 1.3.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - vector_math: 2.1.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - vm_service: 6.0.1-nullsafety.1 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - watcher: 1.0.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - web_socket_channel: 1.2.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - webkit_inspection_protocol: 0.7.5 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - yaml: 3.0.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade" - -flutter: - uses-material-design: true - -# PUBSPEC CHECKSUM: 706a