I often get questions about which tool is better for web application automation. The answer is always that it depends on your situation.
I recommend looking at what already exists before developing something new. (Check out my article Six Open Source Test Tools You Need to Know.)
I do mention Sahi in that post. But after interviewing Narayan Raman, Sahi’s creator, I decided to offer a more in-depth look.
What is Sahi?
The first thing you need to know is that Sahi comes in two flavors: open source and a pro version. Sahi Pro is the enterprise version of the open-source project. It includes lots of features coveted by larger organizations.
For example, compared to the open-source version the pro version has better:
- Parallel Testing
Parallel Testing Differences
With Sahi Open Source, you can run your test in parallel on a single machine. But what if you need to do something more complicated? Let's say you have 1,000 scripts and you want to execute 25 of them in parallel?
For that type of functionality you’d want to use Sahi Pro. The pro version takes care of the distribution, execution and consolidation of reports automatically. With the open-source version these would all be manual activities.
Better Reporting in Sahi Pro
Another benefit of the pro version is reporting.
There are lots of just HTML files in Sahi Open Source that you can use for reporting. Creating reports, however is a manual process.
In Sahi Pro, the result files are more configurable and the data is also stored in the database. Having a database gives you the ability to access metrics and graphs of your test runs. The historic view also shows how your automation suite is progressing.
Why was Sahi Created?
In 2005, Narayan was working at ThoughtWorks. Although they were trying to do lots of things in Agile, there was a problem. They noticed that while development was happening at a much more rapid pace, the testers weren’t able to keep up. They realized that to be more agile they needed more light weight test tools. So they decided to ditch their clunky vendor test tools for something easier to use.
What’s the Difference between Selenium and Sahi?
The development of Selenium was going on at ThoughtWorks around the same time, but Sahi had a different focus; it was created with testers in mind, which is why Narayan made it as simple as possible. Many testers are not developers, which is one of the main reasons that lots of Selenium projects fail.
How does Sahi Work?
Sahi also takes care of waits. For example, it will wait for things like page loads or Ajax activities.
Isn't Using a Recorder for Automation a Bad Thing?
Narayan doesn’t feel that a recorder is always a bad thing. The goal with Sahi is to make the recorder a useful utility. Since Sahi is for testers and not developers, it allows non-technical folks to create maintainable scripts. Thus, testers can focus on testing instead of programming. The tool itself attempts to take care of most of the complexities.
What Tool Should You Use for Test Automation?
What is important for the business? That’s the one question Narayan asks himself when choosing a tool for automation. Too often, folks select tools or languages as a way to boost their resumes. Don't be one of those testers. Check out Sahi and see if it’s the right tool for your business.