diff --git a/integration_test/generate_timelines.sh b/integration_test/generate_timelines.sh index 042826e..95498db 100644 --- a/integration_test/generate_timelines.sh +++ b/integration_test/generate_timelines.sh @@ -1,10 +1,24 @@ -flutter drive \ +flutter --version +fvm flutter build apk \ --dart-define="cameraPreviewAspectRatio=240/320" \ --dart-define="cameraStubImage=assets/camera_stub_image.jpg" \ - --driver=test_driver/performance_driver.dart \ - --target=integration_test/metering_test.dart \ + --target=integration_test/generate_screenshots.dart \ --profile \ - --flavor=dev \ - --no-dds \ - --endless-trace-buffer \ - --purge-persistent-cache + --flavor=dev + +for n in {1..5}; do + echo "============ Run number ${n} ============" + + flutter drive \ + --dart-define="cameraPreviewAspectRatio=240/320" \ + --dart-define="cameraStubImage=assets/camera_stub_image.jpg" \ + --driver=test_driver/screenshot_driver.dart \ + --target=integration_test/generate_screenshots.dart \ + --profile \ + --flavor=dev \ + --no-dds \ + --endless-trace-buffer \ + --purge-persistent-cache \ + --use-application-binary=build/app/outputs/flutter-apk/app-dev-profile.apk +done + diff --git a/lib/application.dart b/lib/application.dart index 5f73ed8..68dd44a 100644 --- a/lib/application.dart +++ b/lib/application.dart @@ -46,61 +46,3 @@ class Application extends StatelessWidget { ); } } - -class AnimatedPickerTest extends StatefulWidget { - const AnimatedPickerTest({super.key}); - - @override - State createState() => _AnimatedPickerTestState(); -} - -class _AnimatedPickerTestState extends State { - Film _selectedFilm = Film.values.first; - - @override - Widget build(BuildContext context) { - return Scaffold( - body: Center( - child: _FilmPicker( - values: Film.values, - selectedValue: _selectedFilm, - onChanged: (value) { - setState(() { - _selectedFilm = value; - }); - }, - ), - ), - ); - } -} - -class _FilmPicker extends StatelessWidget { - final List values; - final Film selectedValue; - final ValueChanged onChanged; - - const _FilmPicker({ - required this.values, - required this.selectedValue, - required this.onChanged, - }); - - @override - Widget build(BuildContext context) { - return AnimatedDialogPicker( - icon: Icons.camera_roll, - title: "Film", - selectedValue: selectedValue, - values: values, - itemTitleBuilder: (_, value) => Text(value.name.isEmpty ? 'None' : value.name), - onChanged: onChanged, - closedChild: ReadingValueContainer.singleValue( - value: ReadingValue( - label: "Film", - value: selectedValue.name.isEmpty ? 'None' : selectedValue.name, - ), - ), - ); - } -} diff --git a/lib/main_dev.dart b/lib/main_dev.dart index f25997e..9ef3faf 100644 --- a/lib/main_dev.dart +++ b/lib/main_dev.dart @@ -1,5 +1,4 @@ import 'package:flutter/material.dart'; -import 'package:flutter/rendering.dart'; import 'package:lightmeter/application.dart'; import 'package:lightmeter/application_wrapper.dart'; import 'package:lightmeter/environment.dart';