takeScreenshot

suspend fun takeScreenshot(hostPath: String)

Captures a screenshot of the current application screen and saves it as a PNG to hostPath.

Convenience alias for screenshot. New code should prefer using screenshot.

Parameters

hostPath

File path on the host machine where the screenshot PNG will be stored.

See also