[Mobile] Take Screenshot


This is a companion discussion topic for the original entry at https://docs.katalon.com/katalon-studio/docs/mobile-take-screenshot.html

How do I compare two screenshot, one is captured manually before strating the execution of script and other one is captured with script,

Please do let us know how we can compare the two screenshot for Mobile.

You can compare 2 png files using aShot.

Hello!

I’m trying to take a screenshot of my app, but for some reason it’s not working.
Seems the take screenshot command is not going out to the Appium server, any ideas?
The script never finishes executing, as if it stuck somewhere.

Here’s a snippet of the code:
// Login is a custom keyword that starts the app and logs in
Login.startApp(appID)
Mobile.takeScreenshot()

And here are the console logs. Note how the takeScreenshot call is not issued (Enjoying the App is the last call before trying to take the screenshot):
2020-03-31 10:19:10.705 WARN k.k.c.m.k.b.WaitForElementPresentKeyword - Object Object Repository/iOS/XCUIElementTypeStaticText - Enjoying the app not found
2020-03-31 10:19:10.708 DEBUG testcase.iOS - 11: takeScreenshot(CONTINUE_ON_FAILURE)
e[35m[HTTP]e[39m e[37m<-- POST /wd/hub/session/352064a5-dfe9-476f-8457-d93f33093745/elements e[39me[32m200e[39m e[90m289 ms - 12e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mPOSTe[39m e[37m/wd/hub/session/352064a5-dfe9-476f-8457-d93f33093745/elementse[39m
e[35m[HTTP]e[39m e[90m{“using”:“name”,“value”:“Enjoying the App?”}e[39m
e[35m[HTTP]e[39m e[37m<-- POST /wd/hub/session/352064a5-dfe9-476f-8457-d93f33093745/elements e[39me[32m200e[39m e[90m285 ms - 12e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mPOSTe[39m e[37m/wd/hub/session/352064a5-dfe9-476f-8457-d93f33093745/timeoutse[39m
e[35m[HTTP]e[39m e[90m{“implicit”:30000}e[39m
e[35m[HTTP]e[39m e[37m<-- POST /wd/hub/session/352064a5-dfe9-476f-8457-d93f33093745/timeouts e[39me[32m200e[39m e[90m11 ms - 14e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/352064a5-dfe9-476f-8457-d93f33093745/contexte[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/session/352064a5-dfe9-476f-8457-d93f33093745/context e[39me[32m200e[39m e[90m10 ms - 22e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/352064a5-dfe9-476f-8457-d93f33093745/contextse[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[RemoteDebugger]e[39m Remote Debugger version 5.7.0
e[35m[RemoteDebugger]e[39m Setting communication protocol: using full Web Inspector protocol communication
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/session/352064a5-dfe9-476f-8457-d93f33093745/contexts e[39me[32m-e[39m e[90m- ms - -e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/session/352064a5-dfe9-476f-8457-d93f33093745/contextse[39m
e[35m[HTTP]e[39m e[90m{}e[39m