How to get the session id of the mobile phone?

101 Views Asked by At

I am doing automation testing for an Android device, but there is an input box that requires filling in a session ID. I don't know how can I get a session ID of the mobile phone?

screenshot

Your help will be appreciated.

1

There are 1 best solutions below

0
tomerpacific On

According to the documentation, you can get the session details through this (Java example):

driver.getSessionDetails();

where driver is the driver you instantiated.

Also, the sessionId is an attribute on the driver itself.

Reference