Remove unused code
This commit is contained in:
Родитель
e9935ecf6e
Коммит
532a898b23
|
@ -85,7 +85,7 @@ class ListPane extends StatelessWidget {
|
|||
? null
|
||||
: BoxDecoration(
|
||||
border: Border.all(
|
||||
color: Theme.of(context).accentColor,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
width: 4,
|
||||
style: BorderStyle.solid,
|
||||
)),
|
||||
|
@ -99,7 +99,6 @@ class ListPane extends StatelessWidget {
|
|||
),
|
||||
),
|
||||
);
|
||||
return Image.asset(images[index]);
|
||||
},
|
||||
itemCount: images.length,
|
||||
);
|
||||
|
@ -185,7 +184,7 @@ class SingleScreenExclusiveRoute<T> extends MaterialPageRoute<T> {
|
|||
|
||||
@override
|
||||
Widget buildContent(BuildContext context) {
|
||||
if (MediaQuery.of(context).hinge?.bounds?.top == 0.0) {
|
||||
if (MediaQuery.of(context).hinge?.bounds.top == 0.0) {
|
||||
navigator?.removeRoute(this);
|
||||
}
|
||||
return super.buildContent(context);
|
||||
|
|
|
@ -1,30 +0,0 @@
|
|||
// This is a basic Flutter widget test.
|
||||
//
|
||||
// To perform an interaction with a widget in your test, use the WidgetTester
|
||||
// utility that Flutter provides. For example, you can send tap and scroll
|
||||
// gestures. You can also use WidgetTester to find child widgets in the widget
|
||||
// tree, read text, and verify that the values of widget properties are correct.
|
||||
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
|
||||
import 'package:design_patterns/main.dart';
|
||||
|
||||
void main() {
|
||||
testWidgets('Counter increments smoke test', (WidgetTester tester) async {
|
||||
// Build our app and trigger a frame.
|
||||
await tester.pumpWidget(const MyApp());
|
||||
|
||||
// Verify that our counter starts at 0.
|
||||
expect(find.text('0'), findsOneWidget);
|
||||
expect(find.text('1'), findsNothing);
|
||||
|
||||
// Tap the '+' icon and trigger a frame.
|
||||
await tester.tap(find.byIcon(Icons.add));
|
||||
await tester.pump();
|
||||
|
||||
// Verify that our counter has incremented.
|
||||
expect(find.text('0'), findsNothing);
|
||||
expect(find.text('1'), findsOneWidget);
|
||||
});
|
||||
}
|
Загрузка…
Ссылка в новой задаче