@Test
public void compareToTest() {

    List<ShapeId> given = Arrays.asList(
            ShapeId.fromParts("ns.foo", "foo"),
            ShapeId.fromParts("ns.foo", "Foo"),
            ShapeId.fromParts("ns.foo", "bar"),
            ShapeId.fromParts("ns.foo", "bar", "member"),
            ShapeId.fromParts("ns.foo", "bar", "Member"),
            ShapeId.fromParts("ns.foo", "bar", "AMember"),
            ShapeId.fromParts("ns.Foo", "foo"),
            ShapeId.fromParts("ns.baz", "foo")
    );
    given.sort(ShapeId::compareTo);
    List<ShapeId> expected = Arrays.asList(
            ShapeId.fromParts("ns.baz", "foo"),
            ShapeId.fromParts("ns.foo", "bar"),
            ShapeId.fromParts("ns.foo", "bar", "AMember"),
            ShapeId.fromParts("ns.foo", "bar", "Member"),
            ShapeId.fromParts("ns.foo", "bar", "member"),
            ShapeId.fromParts("ns.Foo", "foo"),
            ShapeId.fromParts("ns.foo", "Foo"),
            ShapeId.fromParts("ns.foo", "foo")
    );
    assertEquals(expected, given);
}