Friday, 14 June 2013

I added a cover to the book "Java For Testers"

"Java For Testers" started selling really quickly.

And because I did the whole Agile publishing thing, i.e. if the text is 'good enough', then go live.

I went live without a cover.

I have rectified that now, and created a simple, but, in my opinion, adequate cover.


This has a similar style to my "Selenium Simplified" cover, but the lessons I learned from that - in terms of viewing the cover thumbnail were:
  • you need to be able to read the title
  • you need to be able to read the author
  • you don't need to see much else
Compare the above image, to the "Selenium Simplified" cover below and you can see if I learned my lessons.



Java For Testers (Beta Edition) is available for purchase


When I posted that people could join the Beta for "Java For Testers" I was overwhelmed with the responses.

Because of this, I'm using the leanpub.com feature which allows readers to buy the book while it is still being written.

You will receive all updates to the book, without charge, once you have bought it, and you can choose the price you pay. (So long as it is above the minimum payment).

I have set the minimum price to ($4.99) and with each significant update I make to the book after that, I will increase the minimum price. If you buy at an early price then you don't pay anything extra when the price increases.

With leanpub you get all updates to the e-book at no additional cost.

I've taken this step because so many people showed an interest in the book, and it would take me too long to maintain and support the beta list, so I'm going public with the book now.

Some Handy IntelliJ Code Completion Keyboard Short Cut Tips

Assuming you chose IntelliJ as your Java IDE, and why wouldn't you?

There are a few tips I want to pass on for helping with code completion.

I assume you already know Ctrl+Space to start code completion.

In the code completion pop-up you can use Ctrl+Q to see the JavaDoc help for that method.

And if you get stuck with the parameters for a method then Ctrl+P can show you what options are available.

Wednesday, 12 June 2013

How do I get started installing what I need to write Java?

If you want some help getting started with Java then I created a Free online course that includes the setup instructions for:
  • Java
  • Maven
  • Ant
  • an IDE (Eclipse and IntelliJ)
It even has instructions for writing your first test.

Admittedly the course is designed to get you started writing web tests using WebDriver, but in Java. So it has to cover getting started with Java as a prerequisite.

Monday, 10 June 2013

JUnit ExpectedException Rule

JUnit has a new way of testing for Exceptions.
Back in the day, we used to add the expected parameter to the @Test annotation.
@Test(expected = InvalidPassword.class)
But now, JUnit has a new @Rule
@Rulepublic ExpectedException expected = ExpectedException.none();
And you configure the ExpectedException in the @Test method:
expected.expect(InvalidPassword.class);expected.expectMessage("> 6 chars");
Very useful if you want finer grained control over your Exception testing.
You can find out more on the JUnit github.

Friday, 7 June 2013

Which IDE should you use for Java?

There are a whole bunch of free IDEs out there that you could use with Java:

  1. IntelliJ
  2. Eclipse
  3. Netbeans
And there are more, I just listed those that I have tried. You can also use Text Editors as an IDE, some of those even have code completion now.

So which Java IDE should you use?

Well, I use IntelliJ. I even paid for it, which is something that I never thought I'd do for a Java IDE - I do use it for pretty much all my development work: JavaScript, HTML, XML etc.

But that doesn't mean you should use IntelliJ

First thing I recommend you do is:
  •  look around and see what people on your team are using. 
Because chances are you are going to need some support when you start learning Java, and chances are the first people you are going to ask will be the people on your team. 

If you are using the same IDE as the people you are asking for support then you have one less barrier getting in the way, and one less thing adding noise to your problems.

Warning: Don't ask people what you should use. Instead ask what they use. but do it individually, and in secret otherwise you'll start an IDE development flame war

All the IDEs are very good. Some will work faultlessly on your machine, and some won't work. So if you 
encounter initial setup issues, then try another IDE, you might find your problem vanishes. 

Over time you will start to get a feel for what problems are caused by your code, and what problems are environmental related to your machine + your IDE.

If you want help getting started with Eclipse or IntelliJ then my Free Online Start Using WebDriver course has videos explaining how to install Java, Maven and Eclipse or IntelliJ

P.S. But I use IntelliJ.
P.P.S The android dev kit was based on Eclipse, but the next version uses IntelliJ

Thursday, 6 June 2013

Register your interest in the book "Java For Testers"

I'm using Leanpub.com as my writing platform for "Java For Testers".
I've just gone public on the Leanpub site and you can find the book page at:

Leanpub has the handy feature that you can register your interest in the book and will be emailed when the book is published.
You can also let me know how much you would pay for the book when it is published by adding a $amount when you register.

Tuesday, 4 June 2013

Joining the Java For Testers book beta

The private beta of "Java For Testers" has now closed.

The e-book is available at reduced price on leanpub.

You can still comment on the book and influence its direction. If you buy the e-book when it is beta then you get all updates to the e-book without additional charge.


Yes, some of you can read early drafts of the "Java For Testers" book.
If you would like to be part of the private beta, then send me an email to alan(at)compendiumdev.co.uk
Conditions:

  • Tell me your experience level and why you want to review it 
  • You promise not to release the text of the book 
  • If you send comments then you get the next draft of the book to review 
  • I reserve the right to limit the number of people reviewing the beta version so I might have enough people reviewing the book by the time you ask