Last modified by Pascal Robert on 2012/07/19 21:10

Show last authors
1 = How to test a Diva app with Selenium =
2
3 In a 100% ajax world it becomes more than necessary to maintain a set of tests for your application.
4 Here's how to get started with Selenium testing a Diva app.
5
6 === Setup ===
7
8 1. Add the WebObjects {{code language="none"}}ERSelenium{{/code}} framework to your project build path Libraries.
9 1. Create the folder {{code language="none"}}Selenium{{/code}} in the project {{code language="none"}}Resources{{/code}} directory.
10 1. Place your Selenium tests in this folder
11 1. Enable the [[ERSelenium>>doc:documentation.Home.Frameworks.ERSelenium Framework.WebHome]] test-runner by adding {{code language="none"}}SeleniumTestsEnabled=true{{/code}} to the command-line arguments of the app (or to the {{code language="none"}}Properties{{/code}} file).
12
13 You will find an in depth explanation of creating Selenium tests for WebObjects [[here>>doc:documentation.Home.Frameworks.ERSelenium Framework.WebHome]].
14
15 {{info title="Note"}}
16 The semantically rich markup of [[ERDivaLook>>doc:documentation.Home.Frameworks.ERDivaLook.WebHome]] makes it **easy** to write **maintainable** Selenium tests
17 {{/info}}
18
19 === Running Selenium Tests ===
20
21 Launch your application in development mode (i.e with {{code language="none"}}er.extensions.ERXApplication.developmentMode=true{{/code}}).
22 Then click on //Run Test// link in your page menu:
23
24 [[image:attach:RunTests.png]]
25
26 Next you will see the [[ERSelenium>>doc:documentation.Home.Frameworks.ERSelenium Framework.WebHome]] test runner:
27
28 [[image:attach:TestRunner.png]]
29
30 You may run the entire suite of Selenium tests or run them individually by clicking on the buttons marked by the oval.
31
32 See also: [[doc:WO.Selenium]]