People ask me what books I recommend to learn Java. I have a few books that I thoroughly recommend, but they are not aimed at beginners.

I re-read some beginner books recently and came to the conclusion that they would confuse more than help. They don't help people become productive fast.

I wrote a book that gets testers started fast, is easy to follow, and has examples related to their work. I wrote a book I can recommend.

Download a PDF Sample

This page sets out to answer some of the basic questions about “Java For Testers”. If you have any other questions about “Java For Testers” then contact me and I’ll answer, and update this page.

How do I buy it now?

You can buy it in eBook format or paperback.

Do you have an advert or something I can watch first?

Ehmm, yes I do, here you go…

Who is it for?

People who want to learn Java. Particularly people on a team that want to learn Java, but who aren’t going to be coding the main Java application i.e. Testers, Managers, Business Analysts, Front End Developers, Designers, etc.

Why ‘for testers’?

Java Developers coding production applications in Java need to learn Java differently from other people on the team.

Throughout my career I have written thousands of lines of Java code, but I have rarely had to compile the code into an application. Yet, when we learn Java, one of the first things we learn is ‘javac’ and the ‘main’ method.

Most of the code I write is wrapped up in a JUnit @Test method.

Everytime I have taught Java to testers or other people on the team, I start with a JUnit @Test method and show them how to run tests from the IDE.

Testers, and other people on the team use java differently, and I think we need a different order and approach to learning Java.

What if I already know Java?

If you already know Java then this book may not be for you.

It is aimed at beginners.

I cover ‘just enough’ to get people writing tests and abstraction layers, but I don’t really go down into a lot of detail. For example, I cover the basics of Inheritance, but don’t really cover Interfaces in detail. I explain the concept of Interfaces, because we need to know it to understand Collections, but not how to write them.

Why? Because I want to cover enough to get people started, and working. I don’t want to overload them. Once they are on their way, and have gained some experience. Then, when they are ready, they should have the basic knowledge to let them understand the additional concepts.

What topics does the book cover?

This is a high level view of the topics the book covers.

  • JUnit
  • Installing Java, Maven and the IDE
  • Classes
  • Methods
  • Packages
  • Comments
  • Primitive Types
  • Operators
  • Constructors
  • Code Completion
  • AutoBoxing
  • Integer, String, Boolean
  • Static
  • Fields
  • Scope of methods and fields
  • Naming conventions
  • Final
  • Escape Sequences
  • Selection: if, else, ternary operators, switch
  • Iteration: for each, for, break
  • Arrays
  • Collections
  • Inheritance
  • Exceptions, including how to create your own
  • Random Data
  • Dates
  • File Handling
  • Properties
  • Property Files
  • BigDecimal

And since the book is mainly aimed at testers, and working towards testers creating abstraction layers for test automation:

  • all the examples relate to test libraries or abstraction layers
  • we cover the creation and refactoring of Domain Objects

When will it be released?

It is available now!

You can buy it in eBook format or paperback.

Can I see the contents?

What do you think this is? A library?

Just kidding, of course you can. I want you to make sure that this book is right for you before you buy, so I’ve released a 65 page sample with 5 chapters from the book for free, and you can see the contents over at leanpub.com and as a downloadable pdf. The full book has 423 numbered pages, and 23 chapters, with an Appendix full of exercise answers.

Do I have to type in all the code?

It is worth following all the exercises and typing in enough code to experiment. But all the code used in the book, and all the answers for the exercises are available on github.com so you can compare your code with the code that I wrote.

Does the code work?

All the code in the book is extracted directly from the source code.

And all the source code is tested on Windows, Mac and Linux (JDK 1.7, 1.8 and OpenJDK 1.7)

How do I know its any good?

Well, you could read these unsolicited testimonials I found on twitter #JavaForTesters

You can buy the eBook or paperback now