Skip to content

Commit 95b7bd0

Browse files
authored
chore!: remove deprecated parameter (#86)
1 parent ba6db77 commit 95b7bd0

File tree

2 files changed

+0
-21
lines changed

2 files changed

+0
-21
lines changed

lib/src/matchers.dart

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,19 +18,12 @@ import 'package:test/test.dart';
1818
///
1919
/// ```
2020
Matcher isRoute<T extends Object?>({
21-
@Deprecated('Use `whereName` instead') String? named,
2221
Matcher? whereSettings,
2322
Matcher? whereName,
2423
Matcher? whereArguments,
2524
Matcher? whereMaintainState,
2625
Matcher? whereFullscreenDialog,
2726
}) {
28-
// Remove once `named` argument is removed.
29-
if (whereName == null && named != null) {
30-
// ignore: parameter_assignments
31-
whereName = equals(named);
32-
}
33-
3427
assert(
3528
whereSettings == null || (whereName == null && whereArguments == null),
3629
'Cannot specify both `whereSettings` and `whereName` or `whereArguments`',

test/src/matchers_test.dart

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import 'package:flutter/material.dart';
22
import 'package:flutter_test/flutter_test.dart';
3-
import 'package:matcher/src/feature_matcher.dart';
43
import 'package:mockingjay/mockingjay.dart';
54

65
class NonModalRoute extends Mock implements TransitionRoute<void> {}
@@ -49,19 +48,6 @@ void main() {
4948
}
5049

5150
group('constructor', () {
52-
test('wraps deprecated name value in equals matcher', () {
53-
expect(
54-
// ignore: deprecated_member_use_from_same_package
55-
isRoute(named: '/test'),
56-
isA<dynamic>().having(
57-
// ignore: avoid_dynamic_calls
58-
(dynamic m) => m.whereName,
59-
'whereName',
60-
isA<FeatureMatcher<String>>(),
61-
),
62-
);
63-
});
64-
6551
test(
6652
'throws AssertionError when both whereSettings '
6753
'and whereName or whereArguments matchers are provided',

0 commit comments

Comments
 (0)