Selenium with Java binding or Selenium with C# Binding ????

Skip to first unread message


Dec 27, 2017, 1:46:14 AM12/27/17
to webdriver
Hi all, quick question.

 In a company, no automation tool implemented yet, all manual testing. They have development team working on C# .Net. The application is purely web based. Can they go for Selenium with Java binding? 
Please advice.


Dec 27, 2017, 11:03:36 AM12/27/17
to webdriver
Simple answer is Yes, You can even implement using ruby   But since you are a .net builder why wouldn't you use the test tools within MS team studio?

darrell grainger

Dec 29, 2017, 12:34:14 PM12/29/17
to webdriver
WebDriver is a W3 standard for how you can control a web browser. The Selenium bindings are just an implementation which uses WebDriver. Consider this, HTTP is a W3 standard. You can use Chrome or Internet Explorer to surf the web. Some people will use Chrome, some will use Internet Explorer. Does it REALLY matter which browser you select? Not really. Same concept, does it matter which Selenium bindings you use? Not really.

There are some differences however. For example, I cannot use Internet Explorer because I use a macOS computer. I cannot use C# bindings because I use a macOS computer. So if you use C# bindings, your tests cannot be used on a macOS computer. There are ways around this (running a Windows VM on my macOS or using Selenium Grid with hub on macOS but using a Windows node). Java will be available on macOS, Windows and Linux. If your team has people on different operating systems then C# is probably not a good choice.

On the other hand, when I develop test code, I need to know Selenium PLUS I need to use the libraries native to the programming language. If I develop C# programs, I am familiar with the C# libraries. So I can write Selenium tests easier using C#. Knowing the C# libraries will be an advantage if I don't know about the Java libraries (SDK).

You have to figure out what is more important... being able to develop tests on multiple platforms (don't use C#) or leveraging the knowledge of the C# developers. I've worked at companies where all the developers were C# developers and everyone used Windows computers. So we used the C# Selenium bindings. At another company, the team which developed Selenium tests did not interact with the developers at all. They liked Java and many people on the team knew Java. So, even though the web application was written in C#, the tests were written and maintained in Java. A third company had a lot of customers using Safari on the macOS. They needed to test again Safari. The web application was written on C# but the tests were written using Ruby because the test team needed to test against Safari on a macOS.

I program in multiple languages. So working on the web application in C# and the test suite in Java, Ruby or Python isn't a problem for me. But if I ever become a bottle neck, I might not be able to get the web application developers to help me write test methods.

Bottom line, there is no one correct answer here. You can mix and match the web application and test suite languages but it means the people supporting the web application might not be able to help develop or maintain the test suite.

Reply all
Reply to author
0 new messages