Skip to content

Commit cf926ba

Browse files
committed
Use a show over a hide for test_api exports
The members which are currently hidden may get removed from `package:test_api` because they have no uses. dart-lang/test#2030 Switch to a `show` and list all the exported APIs. This is currently a no-op change, and is forward compatible with the breaking change when it lands. A `show` is also safer than a `hide` when exporting across package boundaries. Adding a new member to a library _can be_ breaking, but is often treated as non-breaking. If a new member is added to `package:test_api/scaffolding.dart` it will need to be manually added to the list to be usable from `package:flutter_test`, but we anyways want to add a CHANGELOG entry for user facing changes.
1 parent 68b1891 commit cf926ba

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

packages/flutter_test/lib/src/widget_tester.dart

+14-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,20 @@ export 'package:matcher/expect.dart' hide expect, isInstanceOf;
4747
// that doesn't apply here.
4848
export 'package:test_api/hooks.dart' show TestFailure;
4949
export 'package:test_api/scaffolding.dart'
50-
hide group, setUp, setUpAll, tearDown, tearDownAll, test;
50+
show
51+
OnPlatform,
52+
Retry,
53+
Skip,
54+
Tags,
55+
TestOn,
56+
Timeout,
57+
addTearDown,
58+
markTestSkipped,
59+
printOnFailure,
60+
pumpEventQueue,
61+
registerException,
62+
spawnHybridCode,
63+
spawnHybridUri;
5164

5265
/// Signature for callback to [testWidgets] and [benchmarkWidgets].
5366
typedef WidgetTesterCallback = Future<void> Function(WidgetTester widgetTester);

0 commit comments

Comments
 (0)