Unverified Commit 8fd5d4eb authored by Michael Goderbauer's avatar Michael Goderbauer Committed by GitHub

Remove deprecated SystemNavigator.routeUpdated method (#119187)

* Remove deprected SystemNavigator.routeUpdated

* test fix
parent 578edfc8
......@@ -98,28 +98,4 @@ class SystemNavigator {
},
);
}
/// Notifies the platform of a route change, and selects single-entry history
/// mode.
///
/// This is equivalent to calling [selectSingleEntryHistory] and
/// [routeInformationUpdated] together.
///
/// The `previousRouteName` argument is ignored.
@Deprecated(
'Use routeInformationUpdated instead. '
'This feature was deprecated after v2.3.0-1.0.pre.'
)
static Future<void> routeUpdated({
String? routeName,
String? previousRouteName,
}) {
return SystemChannels.navigation.invokeMethod<void>(
'routeUpdated',
<String, dynamic>{
'previousRouteName': previousRouteName,
'routeName': routeName,
},
);
}
}
......@@ -56,10 +56,6 @@ void main() {
isMethodCall('routeInformationUpdated', arguments: <String, dynamic>{ 'location': 'a', 'state': true, 'replace': true }),
]);
await verify(() => SystemNavigator.routeUpdated(routeName: 'a', previousRouteName: 'b'), <Object>[
isMethodCall('routeUpdated', arguments: <String, dynamic>{ 'routeName': 'a', 'previousRouteName': 'b' }),
]);
TestDefaultBinaryMessengerBinding.instance!.defaultBinaryMessenger.setMockMethodCallHandler(SystemChannels.navigation, null);
});
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment