@Test public void testToString() { versionInfo.setVersion(VERSION_NUMBER_ONE); versionInfo.setFromManifest(true); versionInfo.setTitle(TITLE); versionInfo.setProductID(PRODUCT_ID); assertThat(TO_STRING, equalTo(versionInfo.toString())); assertThat(true, equalTo(versionInfo.isFromManifest())); assertThat(TITLE, equalTo(versionInfo.getTitle())); assertThat(PRODUCT_ID, equalTo(versionInfo.getProductID())); }
@Test public void testGetVersionNumber() { versionInfo.setVersion(VERSION_NUMBER_ONE); assertThat(VERSION_NUMBER_ONE, equalTo(versionInfo.getVersionNumber())); }
@Test public void testSetVersion() { versionInfo.setVersion(VERSION_NUMBER_ONE); assertThat("1", equalTo(versionInfo.getVersionMajor())); assertThat("6", equalTo(versionInfo.getVersionMinor())); assertThat("0", equalTo(versionInfo.getVersionRelease())); assertThat("GA", equalTo(versionInfo.getVersionMilestone())); assertThat("500", equalTo(versionInfo.getVersionBuild())); versionInfo.setVersion(VERSION_NUMBER_TWO); assertThat("1", equalTo(versionInfo.getVersionMajor())); assertThat("6", equalTo(versionInfo.getVersionMinor())); assertThat("0", equalTo(versionInfo.getVersionRelease())); assertThat("RC2", equalTo(versionInfo.getVersionMilestone())); assertThat("400", equalTo(versionInfo.getVersionBuild())); }