java code with tdd