Remove obsolete Cupertino fixture coverage
Keep the shared UI primitive tests focused on the app's Material-only behavior and remove alternate-host fixtures that no longer represent supported rendering.
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
import 'package:pipelines_app/ui/adaptive/floating_destination_bar.dart';
|
||||
@@ -54,11 +53,7 @@ void main() {
|
||||
),
|
||||
child: child,
|
||||
);
|
||||
await tester.pumpWidget(
|
||||
cupertino
|
||||
? CupertinoApp(home: CupertinoPageScaffold(child: body))
|
||||
: MaterialApp(home: Scaffold(body: body)),
|
||||
);
|
||||
await tester.pumpWidget(MaterialApp(home: Scaffold(body: body)));
|
||||
await tester.pumpAndSettle();
|
||||
}
|
||||
|
||||
@@ -80,18 +75,17 @@ void main() {
|
||||
(name: 'phone 560, 5 tabs', size: const Size(560, 844), count: 5),
|
||||
];
|
||||
|
||||
for (final cupertino in [false, true]) {
|
||||
final host = cupertino ? 'Cupertino' : 'Material';
|
||||
{
|
||||
const cupertino = false;
|
||||
const host = 'Material';
|
||||
final diameter = FloatingDestinationBar.buttonSize(cupertino: cupertino);
|
||||
final gap = FloatingDestinationBar.buttonGap(cupertino: cupertino);
|
||||
final iconSize = cupertino
|
||||
? FloatingDestinationBar.cupertinoIconSize
|
||||
: FloatingDestinationBar.materialIconSize;
|
||||
final iconSize = FloatingDestinationBar.materialIconSize;
|
||||
|
||||
test('$host: buttons are larger than the old 44/42 circle, hit targets '
|
||||
'meet the platform minimum', () {
|
||||
expect(diameter, cupertino ? 50 : 52);
|
||||
expect(diameter, greaterThanOrEqualTo(cupertino ? 44 : 48));
|
||||
expect(diameter, 52);
|
||||
expect(diameter, greaterThanOrEqualTo(48));
|
||||
expect(gap, inInclusiveRange(10, 12));
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user