Fixed #1 -> M2_HOME and Maven repo definitions. Refactored some tests