feat(app): pipelines://run/<id> notification links open the run on Android and iOS
This commit is contained in:
@@ -100,4 +100,18 @@ void main() {
|
||||
'/',
|
||||
);
|
||||
});
|
||||
|
||||
test('the native notification link opens its run', () async {
|
||||
const parser = AppRouteParser();
|
||||
final run = await parser.parseRouteInformation(
|
||||
RouteInformation(uri: Uri.parse('pipelines://run/42')),
|
||||
);
|
||||
expect(run, AppRoute.run(42));
|
||||
final decide = await parser.parseRouteInformation(
|
||||
RouteInformation(uri: Uri.parse('pipelines://run/42?action=decide')),
|
||||
);
|
||||
expect(decide.path, '/runs/42?action=decide');
|
||||
// Another scheme or host is not a run link.
|
||||
expect(routeLocation(Uri.parse('pipelines://other/42')), '/42');
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user