Voting Test Plan
This test plan exercises the code used to vote. It can be run either from the main page's sidebar or from the archives page.
Everything shown
- In the Write > Write Poll create and publish a poll.
- Visit the site, at either the home page, or go to the poll in the archives page.
Verify:
- The name of the poll is shown at the top.
- Each option is shown and has a corresponding radio button.
Selecting all the options
- One by one, select each of the option, in random order.
Verify:
- Each option is selectable.
- Only one option is selected at a time.
Voting for nothing
- Get the poll in a state where no option is selected. (Refresh if necessary)
- Press the 'Vote' button.
Verify:
- You are taken to the results page.
- No option had its vote count increased.
Voting for one
- Select an option to vote for.
- Press the 'Vote' button.
Verify:
- You are taken to the results page.
- The option that was selected had its vote count increased by exactly one.
- No other option had its vote count increased.
Clicking Results
- Click the 'Results' link.
Verify:
- You are taken to the results page for the given poll.
- No option had its vote count increased.
Clicking polls
- Click the 'Polls' link.
Verify:
- You are taken to the archives page.
Comments is correct
- Click the 'Results' link.
- Enter 2 comments.
- Return to the voting booth for the poll, either on the sidebar or in the archives.
Verify:
- The comments text reflects the correct number of comments, i.e. 2.
Votes is correct
- Vote for several of the options, multiple times, if you like.
- Return to the voting booth for the poll, either on the sidebar or in the archives.
Verify:
- The Votes text reflects the correct number of total votes.
Back to Main Test Plan