Factorize common build requirements to parent pom.

Parent pom should be available in Maven central in 2 hours max.
merged changes done on github
Added test. Tests on not specified corner cases are marked as Ignored
Merge branch 'master' into asilva