JSON Tests
See the Controller Api wiki page to show you in detail the JSON Syntax for each of the commands in our API. ControllerApi
If you would prefer to write tests in a markup rather than a programming language windmill provides a JSON markup for defining tests. The JSON format is fairly simple, you just define your calls to the windmill API as RPC callbacks in JSON format.
{"method": "open", "params": {"url" : "/"}} {"method": "click", "params": {"link" : "Create a new account"}} {"method": "waits.forElement", "params": {"id": "modalDialogTitle"} } {"method": "asserts.assertNode", "params": {"id": "modalDialogTitle"}} {"method": "click", "params": {"jsid": "{$btnsRight0}"}} {"method": "type", "params": {"text": "{$random}", "id": "username"}} {"method": "type", "params": {"text": "tester", "id": "firstName"}} {"method": "type", "params": {"text": "tester", "id": "lastName"}} {"method": "type", "params": {"id" : "email", "text": "{$random}@osafoundation.org"}} {"method": "type", "params": {"text": "testers", "id": "password"}} {"method": "type", "params": {"text": "tester", "id": "confirm"}} {"method": "click", "params": {"jsid": "{$btnsRight0}"}} {"method": "type", "params": {"text": "tester", "id": "password"}} {"method": "click", "params": {"jsid": "{$btnsRight0}"}} {"method": "click", "params": {"jsid": "{$btnsCenter0}"}}
Moving On
Now you can move along to learning how to run JSON tests in windmill
