void () { UniqueNameBuilder<String> builder = new UniqueNameBuilder<>("", "/"); builder.addPath("A", "/Users/yole/idea/foo/bar.java"); builder.addPath("B", "/Users/yole/idea/baz/bar.java"); assertEquals("foo/bar.java", builder.getShortPath("A")); }