Selenium has the ability to temporarily store data items and then later retrieve them in subsequent tests, e.g.
storeText | @id='ctl00_ContentPlaceHolder1_FormView1' | someValue
This works well within a single test and also between tests in the same Test Suite when a value needs to be carried forward across test boundaries. Unfortunately it doesn’t work between Test Suites (which is a requirement for our application that includes a number of workflows referring to the same object). How can Selenium be used to store values across Test Suite boundaries?
It’s possible to store values from a Selenium Test into the browser’s Local Storage using javascript, e.g. if previously a value had been stored to someValue:
In this case, this.browserbot.getUserWindow() returns the window of the application. This will store someValue into Local Storage from where it can subsequently be retrieved back into the Selenium stored variables.