Why do I prefer Selenium (Ruby) over Watir?

I develop/maintain raw Selenium WebDriver tests with better efficiency.

Zhimin Zhan

--

A week ago, a reader sent me a question “what were your reasons for stopping using Watir in 2010?”

I started real UI test automation with Watir in 2006 (see My Test Automation Journey), and liked it a lot. I even wrote an ebook on Watir. Check out this article for my successful test automation in Watir that enabled real DevOps back in 2009 (when the term not existed yet). I still don’t mind using Watir now if necessary.

Since the release of Selenium 2, (a.k.a, Selenium WebDriver) in 2011, I have been using Watir and raw Selenium at the same time (Watir for Project 1, Selenium for Project 2). Gradually, I found myself using less and less Watir. I like Selenium WebDriver, the raw Selenium WebDriver better: more intuitive and consistent syntax, faster, more reliable, better supported, and easier to learn.

Table of Contents:
1. Raw selenium syntax is actually more natural.
2. Watir became a syntax layer on top of Selenium, anyway
3. Watir shows signs of fading
4. I implemented ‘Attaching existing Window’, the only missing feature in the original Watir, in TestWise
5. It is easier to convince a project to adopt Selenium than Watir.

--

--

Zhimin Zhan

Test automation & CT coach, author, speaker and award-winning software developer. Help teams succeed with Agile/DevOps by implementing real Continuous Testing.