Examples of NumericVersion


Examples of de.idos.updates.NumericVersion

        verify(starter).start(getVersionFolder(), report);
    }

    @Test
    public void deletesOldVersions() throws Exception {
        NumericVersion oldVersion = new NumericVersion(0, 9, 0);
        versionStore.beginInstallation(oldVersion).finish();
        File versionFolder = new File(folder.getRoot(), oldVersion.asString());
        File contentFile = new File(versionFolder, "ContentFile");
        contentFile.createNewFile();
        versionStore.beginInstallation(newVersion).finish();
        versionStore.removeOldVersions();
        assertThat(new File(folder.getRoot(), oldVersion.asString()).exists(), is(false));
    }
View Full Code Here

Examples of de.idos.updates.NumericVersion

        assertThat(new File(folder.getRoot(), oldVersion.asString()).exists(), is(false));
    }

    @Test
    public void keepsNewVersion() throws Exception {
        NumericVersion oldVersion = new NumericVersion(0, 9, 0);
        versionStore.beginInstallation(oldVersion);
        versionStore.beginInstallation(newVersion);
        versionStore.removeOldVersions();
        assertThat(getVersionFolder().exists(), is(true));
    }
View Full Code Here

Examples of de.idos.updates.NumericVersion

        assertThat(getVersionFolder().exists(), is(true));
    }

    @Test
    public void identifiesLatestVersion() throws Exception {
        NumericVersion newVersion = new NumericVersion(0, 2, 0);
        NumericVersion oldVersion = new NumericVersion(0, 0, 8);
        versionStore.beginInstallation(oldVersion).finish();
        versionStore.beginInstallation(newVersion).finish();
        assertThat(versionStore.getLatestVersion(), is(sameVersionAs(newVersion)));
    }
View Full Code Here

Examples of de.idos.updates.NumericVersion

  }

  @Test
  public void returnsLatestUpdate() throws Exception {
    Update latest = lookup.findLatestUpdate();
    assertThat(latest.isUpdateFrom(new NumericVersion(5, 0, 3)), is(UpdateAvailability.Available));
  }
View Full Code Here

Examples of de.idos.updates.NumericVersion

  }

  @Test
  public void returnsLatestUpdate2() throws Exception {
    Update latest = lookup.findLatestUpdate();
    assertThat(latest.isUpdateFrom(new NumericVersion(5, 0, 4)), is(UpdateAvailability.NotAvailable));
  }
View Full Code Here

Examples of de.idos.updates.NumericVersion

  }

  @Test
  public void returnsExpectedUpdateVersion() throws Exception {
    Update latest = lookup.findLatestUpdate();
    assertThat(latest.getVersion(), is(sameVersionAs(new NumericVersion(5, 0, 4))));
  }
View Full Code Here

Examples of de.idos.updates.NumericVersion

        verify(report).lookingUpLatestAvailableVersion();
    }

    @Test
    public void reportsLatestVersion() throws Exception {
        NumericVersion value = new NumericVersion(3, 2, 1);
        when(strategy.findLatestUpdate()).thenReturn(new UpdateDescription(value));
        versionLookup.lookUpLatestVersion();
        verify(report).latestAvailableVersionIs(value);
    }
View Full Code Here

Examples of de.idos.updates.NumericVersion

  }

  @Test
  public void returnsLatestUpdate() throws Exception {
    Update latest = lookup.findLatestUpdate();
    assertThat(latest.isUpdateFrom(new NumericVersion(5, 0, 3)), is(UpdateAvailability.Available));
  }
View Full Code Here

Examples of de.idos.updates.NumericVersion

  }

  @Test
  public void returnsLatestUpdate2() throws Exception {
    Update latest = lookup.findLatestUpdate();
    assertThat(latest.isUpdateFrom(new NumericVersion(5, 0, 4)), is(UpdateAvailability.NotAvailable));
  }
View Full Code Here

Examples of de.idos.updates.NumericVersion

  }

  @Test
  public void returnsExpectedUpdateVersion() throws Exception {
    Update latest = lookup.findLatestUpdate();
    assertThat(latest.getVersion(), is(sameVersionAs(new NumericVersion(5, 0, 4))));
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.