I am trying the below scenario, Any suggestions ?
- open a camera from browser.
- click on the File / Camera from popup
- Click on OK for allowing camera to access files.
- click on take Photo Image
- click on Tick Mark.
Any idea ?
I am trying the below scenario, Any suggestions ?
Any idea ?
MobileElement startRecording = (MobileElement) driver.findElementById(âcom.earningvideo:id/record_buttonâ);
startRecording.click();
Thread. sleep (10000);
System. out .println(âclick on the button start recordingâ);
driver.rotate(org.openqa.selenium.ScreenOrientation. LANDSCAPE );
System. out .println("ââ*-- Now screen orientation Is : "+ driver.getOrientation());
Thread. sleep (5000);
MobileElement closeRecordingScreen = (MobileElement) driver.findElementById(âcom.earningvideo:id/close_cameraâ);
closeRecordingScreen.click();
System. out .println(âcloseRecordingScreenâ);
Thread. sleep (5000);
For me the following codes worked on Android
27 # to open the camera
sleep 3 secs
27 # to make a shot
sleep 3 secs
66 # to click on OK button and return to the app
As for an android virtual device
27 # to open the camera
sleep 3 secs
27 # to make a shot
sleep 3 secs
# please don't ask why about the rest. I just ran a `for` loop to check all possilbe codes and the sequence below just worked fine. If you know anything better, please suggest
sleep 3 secs
55
sleep 3 secs
61
sleep 3 secs
62 # to return to the app