1
0
Fork 0
mirror of https://github.com/ethauvin/kobalt.git synced 2025-04-26 08:27:12 -07:00

Merge pull request #363 from ethauvin/master

file:// no longer considered valid maven coordinates
This commit is contained in:
Cedric Beust 2017-03-28 09:16:58 -07:00 committed by GitHub
commit 33844b616e
2 changed files with 16 additions and 2 deletions

View file

@ -20,6 +20,16 @@ class MavenIdTest {
)
}
@Test
fun isMavenId() {
Assert.assertFalse(MavenId.isMavenId("file://C:\\foo\\bar"))
Assert.assertFalse(MavenId.isMavenId("file:///home/user/foo/bar"))
Assert.assertFalse(MavenId.isMavenId("com.example:foo"))
Assert.assertTrue(MavenId.isMavenId("com.example:foo:"))
Assert.assertTrue(MavenId.isMavenId("com.example:foo:0.5.7"))
Assert.assertTrue(MavenId.isMavenId("com.example:foo:jar:0.3.0"))
}
@Test(dataProvider = "dp")
fun parseVersions(id: String, groupId: String, artifactId: String, version: String?,
packaging: String?, qualifier: String?) {