This specifications to Run code on running JVM.
var time = JavaImporter(java.util.concurrent.TimeUnit)
WDS.browser – This is the Driver Object which represents the Browser. .
WDS.sampleResult – This have all methods applied on results. Like , measuring time, sub sampling, failure state capture. This actually extended functionality of HTTPSampleResults. We can see, we can apply
->Assertion over results
->Sub sampling (breaking big test case in small results)
->Measure time and size for any step
->Get Meta data information of page(like encoding, data types, thread, header, label information like this)
For detail, the API link should be useful. . So, basically, we have to work with WDS.browser which is same as driver object (firefoxdriver) from selenium webdriver.
We need to careful when we are relating selenium code style in webdriver sampler..
1. This is single file code structure, so avoid page object pattern and other utilities . You may use simple screenshots within single script.
var screenshot = WDS.browser.getScreenshotAs(selenium.OutputType.FILE)