@Test
public void shouldParseVersion()
{

    assertThat(Version.of(""), is(Version.of("0")));
    assertThat(Version.of("1"), is(Version.of("1")));
    assertThat(Version.of("12"), is(Version.of("12")));
    assertThat(Version.of("1.2"), is(Version.of("1", "2")));
    assertThat(Version.of("12.34"), is(Version.of("12", "34")));
    assertThat(Version.of("A"), is(Version.of("a")));
    assertThat(Version.of("A"), is(Version.of("alpha")));
    assertThat(Version.of("AB"), is(Version.of("ab")));
    assertThat(Version.of("A.B"), is(Version.of("a", "b")));
    assertThat(Version.of("A.B"), is(Version.of("alpha", "beta")));
    assertThat(Version.of("AB.CD"), is(Version.of("ab", "cd")));
    assertThat(Version.of("1A"), is(Version.of("1", "a")));
    assertThat(Version.of("1A2B"), is(Version.of("1", "a", "2", "b")));
    assertThat(Version.of(".1"), is(Version.of("0", "1")));
    assertThat(Version.of(".A"), is(Version.of("0", "a")));
    assertThat(Version.of("-1"), is(Version.of("0", "1")));
    assertThat(Version.of("-A"), is(Version.of("0", "a")));
    assertThat(Version.of("1."), is(Version.of("1")));
    assertThat(Version.of("A."), is(Version.of("a")));
    assertThat(Version.of("1-"), is(Version.of("1")));
    assertThat(Version.of("A-"), is(Version.of("a")));
    assertThat(Version.of("1.A"), is(Version.of("1", "a")));
    assertThat(Version.of("1-A"), is(Version.of("1", "a")));
    assertThat(Version.of("1.2.3-A"), is(Version.of("1", "2", "3", "a")));
    assertThat(Version.of("1.2.3-A.B"), is(Version.of("1", "2", "3", "a", "b")));
    assertThat(Version.of("1.0.0-SNAPSHOT"), is(Version.of("1", "0", "0", "SNAPSHOT")));
}