mirror of
https://github.com/immich-app/immich
synced 2025-11-07 17:27:20 +00:00
refactor(mobile): riverpod codegen + riverpod lint (#4836)
* build(mobile): add riverpod_lint * refactor(mobile): riverpod_generator for providers * test(mobile): fix integration test helper * refactor: ApiService to riverpod codegen * refactor(mobile): return curatedcontent instead of people dto * refactor: person provider to asyncnotifier * mobile: update service providers to use lambda * mobile: update scaffoldbody default error icon * remove logger mixin --------- Co-authored-by: shalong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
This commit is contained in:
parent
bfab86b70d
commit
983473261b
22 changed files with 732 additions and 175 deletions
|
|
@ -2,7 +2,9 @@ import 'dart:async';
|
|||
|
||||
import 'package:easy_localization/easy_localization.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
import 'package:hooks_riverpod/hooks_riverpod.dart';
|
||||
import 'package:immich_mobile/shared/models/store.dart';
|
||||
import 'package:immich_mobile/shared/providers/db.provider.dart';
|
||||
import 'package:integration_test/integration_test.dart';
|
||||
import 'package:isar/isar.dart';
|
||||
// ignore: depend_on_referenced_packages
|
||||
|
|
@ -40,7 +42,12 @@ class ImmichTestHelper {
|
|||
await Store.clear();
|
||||
await db.writeTxn(() => db.clear());
|
||||
// Load main Widget
|
||||
await tester.pumpWidget(app.getMainWidget(db));
|
||||
await tester.pumpWidget(
|
||||
ProviderScope(
|
||||
overrides: [dbProvider.overrideWithValue(db)],
|
||||
child: app.getMainWidget(),
|
||||
),
|
||||
);
|
||||
// Post run tasks
|
||||
await EasyLocalization.ensureInitialized();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue