9551eceaed
Remove obsolete control-family flags and icon metadata across all callers, dead alternate themes and host helpers, obsolete test setup, and the unused icon-font dependency. Preserve native Material Back transitions. Make navigation fixtures independent of update plugins and answer auxiliary shell snapshots so the complete application suite can run deterministically.
24 lines
1.0 KiB
Dart
24 lines
1.0 KiB
Dart
import 'package:flutter/foundation.dart';
|
|
import 'package:flutter/material.dart';
|
|
import 'package:flutter_test/flutter_test.dart';
|
|
import 'package:pipelines_app/application/app.dart';
|
|
import 'package:pipelines_app/ui/theme/app_theme.dart';
|
|
|
|
void main() {
|
|
for (final platform in TargetPlatform.values) {
|
|
testWidgets('the app uses the Material host on $platform', (tester) async {
|
|
debugDefaultTargetPlatformOverride = platform;
|
|
addTearDown(() => debugDefaultTargetPlatformOverride = null);
|
|
await tester.pumpWidget(const MyApp());
|
|
expect(find.byType(MaterialApp), findsOneWidget);
|
|
// Native hosts keep the target platform so Flutter's automatic
|
|
// behaviours (scroll physics, text selection, back-swipe) still apply.
|
|
final expected = kIsWeb ? TargetPlatform.android : platform;
|
|
expect(appLightTheme().platform, expected);
|
|
expect(appDarkTheme().platform, expected);
|
|
await tester.pumpWidget(const SizedBox.shrink());
|
|
debugDefaultTargetPlatformOverride = null;
|
|
});
|
|
}
|
|
}
|