Betterment / alchemist

A Flutter tool that makes golden testing easy.
MIT License
264 stars 35 forks source link

fix: Tolerance is incompatible with --machine #112

Closed xVemu closed 8 months ago

xVemu commented 8 months ago

Is there an existing issue for this?

Version

/dev/feat/tolerance

Description

When I run flutter test --machine it throws an error. It works great on stable version.

Stacktrace ``` ../AppData/Local/Pub/Cache/git/alchemist-d57c359ceadeae7ebde51639bcf9fbf37bb5f100/lib/src/golden_test_adapter.dart:53:38: Error: A value of type 'void Function(String, Future Function(WidgetTester), {LeakTesting? experimentalLeakTesting, int? retry, bool semanticsEnabled, bool? skip, dynamic tags, Timeout? timeout, TestVariant variant})' can't be assigned to a variable of type 'FutureOr Function(String, Future Function(WidgetTester), {Duration? initialTimeout, bool semanticsEnabled, bool? skip, dynamic tags, Timeout? timeout, TestVariant variant})'. - 'Future' is from 'dart:async'. - 'WidgetTester' is from 'package:flutter_test/src/widget_tester.dart' ('.fvm/flutter_sdk/packages/flutter_test/lib/src/widget_tester.dart'). - 'LeakTesting' is from 'package:leak_tracker_testing/src/leak_testing.dart' ('../AppData/Local/Pub/Cache/hosted/pub.dev/leak_tracker_testing-2.0.1/lib/src/leak_testing.dart'). - 'Timeout' is from 'package:test_api/src/backend/configuration/timeout.dart' ('../AppData/Local/Pub/Cache/hosted/pub.dev/test_api-0.6.1/lib/src/backend/configuration/timeout.dart'). - 'TestVariant' is from 'package:flutter_test/src/widget_tester.dart' ('.fvm/flutter_sdk/packages/flutter_test/lib/src/widget_tester.dart'). - 'Object' is from 'dart:core'. - 'Duration' is from 'dart:core'. TestWidgetsFn defaultTestWidgetsFn = testWidgets; ^ ```