LCOV - code coverage report
Current view: top level - problems/pages - problem_page.dart (source / functions) Hit Total Coverage
Test: lcov.info Lines: 12 12 100.0 %
Date: 2022-03-03 12:16:56 Functions: 0 0 -

          Line data    Source code
       1             : import 'package:flutter/material.dart';
       2             : 
       3             : import '../../../types.dart';
       4             : import '../widgets/problem_page_view.dart';
       5             : 
       6             : /// Creates a widget to show an error from a type of [ProblemInfo].
       7             : /// The [ProblemPage] is used for alerting a user to an error.
       8             : class ProblemPage<T extends RedFireState> extends Page<dynamic> {
       9             :   final ProblemInfo info;
      10             : 
      11           1 :   ProblemPage({
      12             :     required this.info,
      13           2 :   }) : super(key: ValueKey(info));
      14             : 
      15             :   // const ProblemPage(this.info, {Key? key}) : super(key: key);
      16             : 
      17           1 :   @override
      18             :   Route createRoute(BuildContext context) {
      19           1 :     return PageRouteBuilder<dynamic>(
      20             :       settings: this,
      21           1 :       pageBuilder: (context, animation, animation2) {
      22           1 :         final tween = Tween(begin: const Offset(0.0, 1.0), end: Offset.zero);
      23           1 :         final curveTween = CurveTween(curve: Curves.easeInOut);
      24           1 :         return SlideTransition(
      25           2 :           position: animation.drive(curveTween).drive(tween),
      26           1 :           child: ProblemPageView<T>(
      27           1 :             info,
      28           2 :             key: ValueKey(info),
      29             :           ),
      30             :         );
      31             :       },
      32             :     );
      33             :   }
      34             : }

Generated by: LCOV version 1.13