-
-
Notifications
You must be signed in to change notification settings - Fork 183
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to pass JWT token via extras in startActivity method #848
Comments
not sure what is the problem here. The token string is base64-encoded. It does not have any chars that require escaping |
I use package https://www.npmjs.com/package/react-native-launch-arguments The thing is that:
which plugin is executing doesn't work. I did small investigation and "" doesnt matter. When I run this command in CMD - get response which looks like:
It seems extras aren't passed to the activity. (?) I tried different approach and I added -n before my_package/my_activity and
and response from emulator was:
also package from react native manage to fetch my extras. I tried to pass also via driver.execute additional parameter "component" which was the same like intent:
'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJhZDE4MTg3OS02NzdjLTQzODQtOTE0NC0xMmY0M2FhOTJiMjkiLCJ1bmlxdWVfbmFtZSI6ImFkMTgxODc5LTY3N2MtNDM4NC05MTQ0LTEyZjQzYWE5MmIyOSIsImp0aSI6IjIxYmU3NzcxLTU1OTAtNDVjOS1hNTgyLTVjOTBjNTM0ZDc0OCIsImlhdCI6IjE3MzM4MzcyMTU4MDkiLCJodHRwOi8vc2NoZW1hcy5taWNyb3NvZnQuY29tL3dzLzIwMDgvMDYvaWRlbnRpdHkvY2xhaW1zL3JvbGUiOiJDbGllbnQiLCJuYmYiOjE3MzM4MzcyMTUsImV4cCI6MzMyMzgzMDEyMTUsImlzcyI6ImJlYXV0eWJveCJ9.BuAOPTVC1GXX4zSwH0ItP-yfsxvcFng90bp44lXeuvA',
but still response was:
The easiest way to resolve it I think would be mark intent as optional but maybe problem is somewhere else? |
Hi.
Im trying to pass via extras random JWT token to my activity. My code looks in a following way:
In appium logs I see that under the hood command is not parsed correctly:
It looks like there are missing ' ' in the start and end of JWT passed to ADB. In documentation there is said also that string must be valid - what does it mean?
The purpose of passing JWT via extras is to have possibility to skip whole login/register flow and speed up my tests.
The text was updated successfully, but these errors were encountered: