Testers Learning To Code

One of the topics that always pops up in conversation with Testers is whether or not we need to know how to code.

I think a lot of this depends on your context and your career goals and aims, but really it pays to at least understand how the code is hanging together and to get a sense of what it’s doing. It would undoubtedly be useful to code at a basic level to help build tools and programs to help you and also to crack Test Automation (i.e. not relying on Record and Playback as your strategy).

I often hear the excuse that there isn’t time to learn, but I don’t think this is true. I think we could all snaffle 10 minutes a day to work on some code. The time argument depends greatly on the importance you place on learning to code. There are lunch times and after work and weekends too.

One of the things we’ve got set up within our team is two 30 minute sessions each week where the whole test team sit together and work through coding katas with our tech tester and programmer. It works really well but still needs each Tester to spend a little extra time each week re-enforcing the learning.

I thought I would collate together some resources that might help and inspire you. Oh yeah, and deciding which language to learn is often the hardest decision. I can’t offer any guidance on that really, it’s what works best for your environment, your product, your goals and your interest in each language.

So here are a few resources I’m finding helpful:

So you want to learn programming basics?

There are loads of resources for learning basic programming (try a Google search for it) but the one that stands out from the crowd is Code Academy. It’s a great interactive tutorial teaching you the basics using JavaScript as it’s main language. The lessons are short and the guidance is awesome.

So you want to learn Python?

Python is a really powerful scripting language and you would be surprised at how many of your favourite sites are running on it on the web.

There are a number of great resources available on Python but one of my favourites is this very straight forward guide called “The Programming Historian“. The lessons are kept simple and you’ll be writing Python to manipulate files and text in no time.

If you’re in a .Net environment then IronPython might be the way to go.

By far the most relevant and intuitive book on Java for Testing is Alan Richardson’s “Selenium Simplified“. The guide is very straight forward and in no time you’ll have some tests running on your web site. It’s obviously aimed at getting you started with Selenium but Alan introduces you to Java as part of the journey.

Update – Alan has also now released Java For Testers. Head over to the site and check it out.

Hi Rob, didn’t you forget PowerShell?
This is almost so allmighty as compiled Framework languages (can be compiled too, but it’s not common practice) , on the other hand, PowerShell shortens the code testers need to write, thus eliminating bugs in test code.
There are several frameworks, and the number is growing. What’s more, all the testing automation frameworks for .NET can be used as it’s a .NET language (and an inclusion of C# code, for example) is also possible.

As far as I know, for now PowerShell is already the best choice for several test teams.

I know its an old post, and thanks for including Selenium Simplified in the list of Java books. I’ve now released ‘Java For Testers’ which specifically concentrates on teaching Java with more focused coverage and a wider range of examples and exercises.