LCOV - code coverage report
Current view: top level - lib - app_state.dart (source / functions) Hit Total Coverage
Test: lcov.info Lines: 6 8 75.0 %
Date: 2022-03-03 12:16:04 Functions: 0 0 -

          Line data    Source code
       1             : import 'package:fast_immutable_collections/fast_immutable_collections.dart';
       2             : import 'package:freezed_annotation/freezed_annotation.dart';
       3             : import 'package:redfire/types.dart';
       4             : 
       5             : import 'challenges/models/challenge_model.dart';
       6             : import 'game/game_state.dart';
       7             : 
       8             : part 'app_state.freezed.dart';
       9             : part 'app_state.g.dart';
      10             : 
      11             : @freezed
      12             : class AppState with _$AppState, RedFireState {
      13             :   factory AppState({
      14             :     /// RedFire AppState members
      15             :     required AuthState auth,
      16             :     @PageDataConverter() required IList<PageData> pages,
      17             :     required IList<ProblemInfo> problems,
      18             :     required Settings settings,
      19             :     ProfileData? profile,
      20             : 
      21             :     /// Additional AppState members
      22             :     required GameState game,
      23             :     @ChallengeModelConverter() ChallengeModel? challenge,
      24             :   }) = _AppState;
      25             : 
      26           2 :   factory AppState.init() => AppState(
      27             : 
      28             :       /// RedFire init code
      29           1 :       auth: AuthState.init(),
      30           2 :       pages: <PageData>[const InitialPageData()].lock,
      31           1 :       problems: IList(),
      32           1 :       settings: Settings.init(),
      33             : 
      34             :       /// Additional init code
      35           1 :       game: GameState.init());
      36             : 
      37           0 :   factory AppState.fromJson(Map<String, Object?> json) =>
      38           0 :       _$AppStateFromJson(json);
      39             : }

Generated by: LCOV version 1.13