Posted by: Brian | September 17, 2008

The Truth about Test Automation and Coding

The Rational Tester is often asked the following question:

“Do I need to be a programmer to implement test automation?”

 

It’s a valid concern, especially when certain other vendors (that were recently acquired by a printer company) herald their test automation tool so simple, that pre-schoolers can generate tests.  While there is a grain of truth in there, the reality of test automation is that once you get beyond the basics, you are going to need to have some coding aptitude.  You’ll also need a good coding environment, and this in part, was why Rational Functiona Tester was built upon Eclipse – an excellent all purpose coding environment.

You do not, I repeat, do not need to have a Ph.D in Computer Science or Engineering to be a test automator.  I would however argue, that you do need to be a “scripter”.  A scripter means you understand basic coding structures such as loops and decision structures, like if…then type logic.  A scripter means you understand the basics of variables, like integers and strings.  Knowing the difference between a long and  short is probably going too far.

The other key point I’ll make here is that coding, or should I really say scripting, with test automation is very repetitive.  You find yourself repeating the same types of script edits over and over.  You also can benefit a lot from the Google – as any code you likely need as a test automator has already been written.

In the upcoming posts, I’ll attempt to post some of my more common code snippets, to help first time automators get themselves up and running.

Advertisements

Responses

  1. Hi Brian,

    I agree with you completely… Codeless automated testing does not exist. Of course you can record a script in some tools without having to code, but to truly implement a viable automation solution you will need to do some coding or indeed better said scripting.

    Please don’t try to be a developer. I have seen it before where a “brilliant” automator who knew the tool and scripting language in and out developed a solution to test a online banking site. The code dealt with every permutation imaginable. Problem was the guy left and someone else had to take it over as the AUT had changed… after a week of pulling his hair out it was decided it was cheaper to recode the whole script.

    A simple scripter who knows the basics of coding and even better understands the true concept of test automation is a lot more valuable than a developer … in the test arena of course.

    After all who is going to test the tester’s code? Keep it simple!

    Cheers


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Categories

%d bloggers like this: