import 'dart:async'; import 'package:flutter_test/flutter_test.dart'; import 'package:kouyu_english/core/courses/course_repository.dart'; /// Every test sees the A0 course, just like the app after `main` loads it. Future testExecutable(FutureOr Function() testMain) async { TestWidgetsFlutterBinding.ensureInitialized(); await CourseRepository.instance.load(levels: {'A0'}); await testMain(); }