LCOV - code coverage report

Current view
top level - src/_impl/xplat - _internal_logger.dart
Test
lcov.info
Date
2024-11-13
Legend
Lines
hit
not hit
Branches
taken
not taken
# not executed
HitTotalCoverage
Lines111764.7%
Functions00-
Branches00-
Each row represents a line of source code
LineBranchHitsSource code
1import 'package:logger/web.dart';
2
3class InternalLogger extends Logger {
410 InternalLogger()
59 : super(
69 filter: _LogAllFilter(),
79 printer: _DummyPrinter(),
89 output: _NoLogOutput(),
9 );
10}
11
121class _NoLogOutput extends LogOutput {
139 @override
140 void output(OutputEvent event) {
15 // Do nothing in this logger (which lives in the worker thread).
16 // The log event will be captured and forwarded to the channelLogger (which
17 // lives in the main thread).
180 }
19}
20
211class _DummyPrinter extends LogPrinter {
229 @override
230 List<String> log(LogEvent event) =>
24 // Logger will ignore log events that produce an empty array.
25 // Make sure the array is not empty so the log event is notified
26 // through Logger's output callbacks.
270 const [''];
28}
29
301class _LogAllFilter extends LogFilter {
319 @override
320 bool shouldLog(LogEvent event) =>
33 // Log everything. It's up to the receiving channelLogger to decide
34 // whether the message should be logged or not.
350 true;
36}
Choose Features