I am executing JSON Script in CA DevTest using Selenium Step and I need to take screenshots of all the actions (or pages) when I execue my test.Can someone please help me in this regard.
Every Selenium Step executed in DevTest will automatically take screenshot implicitly, and the screenshot can be viewed in the Portal.
You can also create an Execute script (JSR-223) step after each Selenium step you want to save the screen on with the below code, (modify the selenium.PNG per step to save multiple screen shots)
import org.apache.commons.io.*; String screenEncoded = testExec.getStateObject("selenium.last.screenshot"); byte screenDecoded = Base64.decode(screenEncoded); FileUtils.writeByteArrayToFile(new File("c:\\temp\\selenium.PNG"),screenDecoded);
What version of DevTest are you on?
Retrieving data ...