Telerik Testing Framework vs Selenium

Telerik Inc. is the company behind the popular KendoUI JavaScript widgets and they make some other stuff as well. The Telerik Testing Framework is among their less known offerings. It’s a UI automation framework for web applications i.e. you get an API that allows you execute actions within a browser instance (e.g. clicking on a button). It’s an alternative to Selenium WebDriver and it works much the same way and like Selenium it’s FREE.

There might be a bit of confusion here. Telerik also offers a tool by the name of Test Studio which utilizes the Telerik Testing Framework internally. Test Studio is designed to let you create tests without writing code and is NOT a free product.

So back to Telerik Testing Framework.
Is it really a valid alternative to Selenium? Well, we just implemented an entire test suite from scratch for a customer. And it works just fine. There are no fundamental issues that take it out of the running. You will be able to build stable UI tests and run them as part of your CI process.

Should you use Telerik Testing Framework over Selenium?

Telerik Testing Framework is a .Net library and as such you’ll be using it within Visual Studio and you’ll be writing your code in C# or VB. You can use the free version of Visual Studio. But you can’t use it with any other languages unlike Selenium which has distributions for Java, Python etc.

The other thing is adoption. It’s safe to assume that Selenium has a much bigger user base. This is generally good because it means you can get a lot of support from the community in places like StackOverflow. The Telerik Testing Framework does have its own message board and a dedicated support team that is activate there. This helps somewhat but it’s no substitute for a big community. When we used Telerik Testing Framework we had to come up with our own best practices and custom solutions in some cases. We’ll write those up in future blog posts for your benefit. And a lot of best practices are shared between both frameworks because they’re so similar. But the bottom line is there’s a lot more info on Selenium.

Telerik Testing Framework doesn’t support CSS selectors and you’ll have to use a lot of Xpath instead. This has certain advantages but it can get annoying particularly if you don’t know Xpath.

Keep in mind that to build a test suite you’ll need to develop your own framework on top of Selenium/Telerik Testing Framework. Selenium and Telerik Testing Framework are just APIs that allow you to send actions to the browser and you’ll need a lot of abstraction around them to handle the complexity of modern web apps.

Telerik itself has a big community around some of its other products and if you’re already a Telerik fan Telerik Testing Framework is worth checking out. Telerik Testing Framework does work nicely if you plan to use it along side Telerik’s Test Studio in which case you can use Test Studio’s test results dashboard and other features. We’ll elaborate on that in another blog post.

Lastly here’s a side-by-side comparison of a “test” that navigates to Wikipedia, types in the searchword ‘Integration test’ and clicks the ‘Search’ button. This should give you an idea how similar these frameworks really are. The Telerik Testing Framework takes a few more lines of code to setup but that’s irrelevant.

Selenium:

FirefoxDriver firefox = new FirefoxDriver();
firefox.Navigate().GoToUrl("https://www.wikipedia.org/");
firefox.FindElement(By.Id("searchInput")).SendKeys("Integration Test");
firefox.FindElement(By.ClassName("formBtn")).Click();

Telerik Testing Framework:

Settings mySettings = new Settings();
mySettings.Web.DefaultBrowser = BrowserType.FireFox;
Manager myManager = new Manager(mySettings);
myManager.Start();
myManager.LaunchNewBrowser();
myManager.ActiveBrowser.NavigateTo("https://www.wikipedia.org/");
myManager.ActiveBrowser.Find.ById("searchInput").Text = "Integration Test";
myManager.ActiveBrowser.Find.ByName("go").Click();

Need help with your test automation? Let’s work together!

One thought on “Telerik Testing Framework vs Selenium

Leave a Reply

Your email address will not be published. Required fields are marked *