Suite setup
Use this page to prepare a FitNesse suite so every test can use the Reflex fixtures. Put the setup in a SuiteSetUp.wiki page. It runs before any test in the suite.
SuiteSetUp example
Section titled “SuiteSetUp example”!|import ||nl.hsac.fitnesse.fixture ||nl.hsac.fitnesse.fixture.slim ||reflex.slim.fixtures |
|script |conf fixture||stopOnException;|true ||browserHeadless;|false ||browserTimeout; |10000 |
|script|browser download||chrome |The import table makes these packages available:
| Package | Contents |
|---|---|
nl.hsac.fitnesse.fixture | HSAC base fixtures |
nl.hsac.fitnesse.fixture.slim | SLIM fixtures |
reflex.slim.fixtures | Reflex fixtures (browser, REST, Lua and more) |
browser download fetches the Chrome driver that matches your system. Run it before browser tests.
Settings
Section titled “Settings”Set these with conf fixture. You can also set them again in a single test.
| Method | Type | Default | Description |
|---|---|---|---|
stopOnException | boolean | true | Stop the test at the first failure |
browserHeadless | boolean | true | Run the browser without a window |
browserTimeout | number | 10000 | Browser timeout in milliseconds |
browserWidth | number | 1920 | Window width |
browserHeight | number | 1080 | Window height |
databaseUrl | string | none | JDBC URL |
databaseUser | string | none | Database user |
databasePassword | string | none | Database password |
SuiteTearDown
Section titled “SuiteTearDown”Create a SuiteTearDown.wiki page for cleanup after all tests. It can be empty.
File layout
Section titled “File layout”FitNesseRoot/ Examples/ Reflex.wiki # Suite page SuiteSetUp.wiki SuiteTearDown.wiki Reflex/ test1.wiki # One test test1.lua # Its Lua file helpers.lua # Shared Lua codeNext: Write tests.