Anonymous User
|
Selenium Day Notes, Reference, and Best Practices
Getting Started:
- Grab a test plan from the counter near the table (where the food is).
- SSH to the machine
bugday.cnx.rice.edu, and enter the directory /opt/zope/bugday/Products/CNXSeleniumTests/skins/CNXSeleniumTests
- Figure out what your test plan is basically called, like "Links" or "Forking". Copy the file
SDSampleTestSuite.html.dtml and call the file (for example) SDForking.html.dtml.
- Copy
SDSampleTestPlan.html.dtml to something like SDForking-Modules.html.dtml.
- Edit the suite file to point to your first test plan file -- that is, replace the string
SDSampleTestPlan.html with the name of your test plan file.
- Edit the test plan file to start building tests. To run your tests, go to, e.g.,
http://bugday.cnx.rice.edu/TestRunner.html?test=SDForking.html
Reference links:
Best Practices (if you have one, add it!)
- Maximize rigor, minimize fragility
- Given a choice among addressing schemes, use the one that's most specific, but least likely to change over time.
- Use the simplest addressing scheme that works consistently, e.g.: link=, then id=, then name=, etc.
- Use goBackAndWait instead of goBack. More than one goBack without a pause and you will likely get errors. Thanks, Cameron!
File locations
- ssh to bugday:/opt/zope/bugday/Products/CNXSeleniumTests/skins/CNXSeleniumTests
- Sample files:
- SDSampleTestSuite.html.dtml
- SDSampleTestPlan.html.dtml
Naming scheme
- For today, let's start everything with "SD" for SeleniumDay?. I can regularize them later.
- Name your test suite files SD[something].html.dtml and your test plan files SD[something]-[somethingelse].html.dtml.
- Example: SDLinks.html.dtml and SDLinks-AddLinks.html.dtml.
- Studly caps (internal capitalization, meaning "mixed caps", or init-capped words) makes things easier to read.
TestTest
|