1

So, I just downloaded the Selenium WebDriver and the ChromeDriver and got a sample working in VS2013. All is good so far, but then I started thinking about how I would write regression tests on an internal site and the thought of painstakingly writing the script by hand to open the site, navigate the pages, and check the values struck me as tedious.

I saw the FireFox IDE, which looks promising except we don't have FireFox and can't install it.

What are people doing to generate scripts in Chrome or IE aside from hand-coding or using the FireFox IDE software?

6
  • I am quite confident that you find most people do not "generate" scripts but as you said "hand-code" them. "Generated" scripts are pretty limited. "Hand-coded" are limited only by the level of your programming skills. Aug 18, 2015 at 20:26
  • Yeah, I figured I would need to tweak the scripts, but if something generated 90% of what I needed... Aug 18, 2015 at 20:29
  • 2
    90% of what you need is creating custom pageobjects. Aug 18, 2015 at 22:02
  • Agreed with Peter Masiar. 90% of what you need are page objects and Selenium IDEs do not generate PageObjects.
    – dzieciou
    Aug 19, 2015 at 5:26
  • katalon studio is a good tool to generate scripts and take care of running this in all browsers. Oct 26, 2017 at 14:03

3 Answers 3

2

One of the strengths of WebDriver is how powerful it is as a programming tool. It gives you the full power of the language whose bindings you're using. No generation tool is going to be able to generate even 90% of what you want. Tools like Firefox IDE will only at best generate something that you can use as a baseline if theres a piece you're having trouble figuring out, but there will be zero optimization and error correction if anything were to go awry.

WebDriver doesn't require very much programming skill to get started, but, you'll find that by hand writing your tests that your automation will improve with you. If you want to rely on a program to do most of the scripting work for you, you might be better off choosing another automation framework that has a better feature set for what you're looking to get out of it.

2

I agree with what the people said, but just in case, you could check this out: Selenium Builder https://saucelabs.com/builder I've used it and I prefer this approach rather than IDE, however, after you learn the main commands, it's better to directly code your scripts.

2

You will not get too far with test automation by relying on record and playback.

Test automation tools (QTP, RANOREX) typically allow you to make changes to the recorded script in an action grid.

But the changes that you can make are very limited.

On the other hand, if you look at the code that resulted from the recording, it is very difficult to read, understand and change.

It pays off to make the effort of learning a programming language, unit testing, a test automation framework and page object model.

Disclaimer: poster is the author of the linked blog post.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.