[android_engine_test] Remove background/foreground from surface texture trampoline test. (#161441)

See if this fixes the golden. The background/foreground isn't necessary
for this test which is just a gold comparison of the rendering
This commit is contained in:
Jonah Williams 2025-01-11 13:16:21 -08:00 committed by GitHub
parent 00b6a4ed06
commit bd1ebf2e14
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -12,8 +12,6 @@ import '_luci_skia_gold_prelude.dart';
void main() async {
// To test the golden file generation locally, comment out the following line.
// autoUpdateGoldenFiles = true;
const String appName = 'com.example.android_engine_test';
late final FlutterDriver flutterDriver;
late final NativeDriver nativeDriver;
@ -31,21 +29,9 @@ void main() async {
await flutterDriver.close();
});
test('should screenshot and match an external smiley face texture', () async {
test('should screenshot and match a smiley face texture using the trampoline', () async {
await flutterDriver.waitFor(find.byType('Texture'));
// On Android: Background the app, trim memory, and restore the app.
if (nativeDriver case final AndroidNativeDriver nativeDriver) {
print('Backgrounding the app, trimming memory, and resuming the app.');
await nativeDriver.backgroundApp();
print('Trimming memory.');
await nativeDriver.simulateLowMemory(appName: appName);
print('Resuming the app.');
await nativeDriver.resumeApp(appName: appName);
}
await expectLater(
nativeDriver.screenshot(),
matchesGoldenFile('external_texture_other_face.android.png'),