BarCamp: Session on Selenium by Nelz
It's lunch now today at BarCamp. I've met a bunch of great people and been in two really awesome sessions so far. The second session I went to was
Nelz's session on Selenium which is a tool for Firefox for testing a website. As I was sitting through the presentation I took down some notes and I'll just drop them below. Forgive me for the errors.
Selenium <-- AKA: a cure to mercury poisoning.
- Runs across OS's and browser.
- Uses Javascript and iFrames to embed a test into your browser. Drives your app. Interact with JS to emulate user actions.
- It can control starting the browser and closing it. AUTOMATED TESTING!
- Selenium IDE
- Has debugging
- Easy selection of on page elements
- Recording and playback of the tests. Just start the recording, step through the pages and then save the recording. The script of the steps can then be passed onto other developers easily or other people with Selenium to do the test themselves.
- Saves tests off in multiple formats such as Ruby, PHP...
- Shortcomings of IDE
- Firefox only
- The recorded session can be played in any browser.
- Sometimes thrown off by AJAX events.
- No one does RAILs at this presentation.
- Tests can be handed off to other people so that they can run the test themselves to see the issue as well. Great for showing the problem.
- A script of the test can be exported as Java, C#, HTML, Python, Ruby so that Selenium Remote Control can run the script as part of the main tests.
- Doesn't to browser version testing.
- "Click and Wait" can have a wait time set for it.
- J-Meter can be used for performance testing.
- Fitness is another testing tool.
- Look into Floyd for testing browser tests. It speaks to the browser via the browser API.
- Javascript has limitations because of the security.