Files
SpotiFLAC-Mobile/test/log_export_rendering_test.dart
zarzet 5ec74de01c feat(diagnostics): add renderer and glass level to log exports
Smoothness reports such as issue #841 depend on whether the engine runs
Impeller or Skia and on the Mornye glass level, and neither showed in
copied or shared logs. The export now has a Rendering block with the
renderer (told apart by shader filter support) and the glass level.
2026-11-07 20:14:26 +07:00

31 lines
916 B
Dart

import 'package:flutter_test/flutter_test.dart';
import 'package:mornye/utils/logger.dart';
void main() {
TestWidgetsFlutterBinding.ensureInitialized();
test('the renderer line tells Impeller from Skia', () {
expect(
rendererDiagnosticLine(shaderFilters: true),
'Renderer: Impeller (shader filters supported)',
);
expect(
rendererDiagnosticLine(shaderFilters: false),
'Renderer: Skia (no shader filters)',
);
});
test('the log export carries the renderer and glass level', () async {
final export = await LogBuffer().exportWithDeviceInfo(
glassLevel: 'frosted',
);
expect(export, contains('--- Rendering ---'));
expect(export, contains(rendererDiagnosticLine()));
expect(export, contains('Glass Level: frosted'));
expect(
export.indexOf('--- Rendering ---'),
lessThan(export.indexOf('--- Log Summary ---')),
);
});
}