detox-expo-helpers
detox-expo-helpers copied to clipboard
Add URLQuery parameters to test deep linking
An item I was looking to test with Expo and Detox was the deep linking by receiving a set of URL parameters when initially opening the application. Not sure if it is helpful for anyone else, but I created a version where a parameter can be passed into the reloadApp() function to simulate the url creation.
For instance, if I wanted to simulate the user clicking on myapp://+?id=1000, I can now pass in the following:
let params = {
urlQueryString: {
id:"1000"
}
};
await reloadApp(params);