MavenVersionUtil { public static boolean isSnapshot(String version) { return version.toUpperCase().endsWith(VERSION_QUALIFIER_SNAPSHOT) || version.toUpperCase().equals(VERSION_LATEST); } private  MavenVersionUtil(); static boolean isSnapshot(String version); static String calculateNextSnapshotVersion(String version, VersionUpgradeStrategy upgradeStrategy); static String calculateNextSnapshotVersion(String version); static String calculateReleaseVersion(String version); static boolean isNewerVersion(String version1, String version2); static final String VERSION_QUALIFIER_SNAPSHOT; static final String VERSION_LATEST; }
@Test @UseDataProvider("isSnapshot") public void testIsSnapshot(String version, boolean expectedResult) { Assert.assertEquals(expectedResult, MavenVersionUtil.isSnapshot(version)); }