We use the Eclipse built-in Java Conventions formatter file, except for one difference: we have a line width of 180, instead of 80, as usually the screen allows much longer lines than 80.
We use JUnit to implement the unit tests. Take a look at the [Getting started] (http://junit.sourceforge.net/) documentation at http://junit.org.