Examples of Release


Examples of com.jcabi.github.Release

     * Smart decorator returns tag name.
     * @throws Exception If some problem inside
     */
    @Test
    public void canGetTag() throws Exception {
        final Release release = MkReleaseTest.release();
        final Release.Smart smart = new Release.Smart(release);
        MatcherAssert.assertThat(
            smart.tag(),
            Matchers.equalTo(this.value(release, "tag_name"))
        );
View Full Code Here

Examples of com.jcabi.github.Release

     * Smart decorator returns target commitish.
     * @throws Exception If some problem inside
     */
    @Test
    public void canGetCommitish() throws Exception {
        final Release release = MkReleaseTest.release();
        final Release.Smart smart = new Release.Smart(release);
        MatcherAssert.assertThat(
            smart.commitish(),
            Matchers.equalTo(this.value(release, "target_commitish"))
        );
View Full Code Here

Examples of com.jcabi.github.Release

     * Smart decorator returns name.
     * @throws Exception If some problem inside
     */
    @Test
    public void canGetName() throws Exception {
        final Release release = MkReleaseTest.release();
        final Release.Smart smart = new Release.Smart(release);
        MatcherAssert.assertThat(
            smart.name(),
            Matchers.equalTo(this.value(release, MkReleaseTest.NAME))
        );
View Full Code Here

Examples of com.jcabi.github.Release

     * Smart decorator returns body.
     * @throws Exception If some problem inside
     */
    @Test
    public void canGetBody() throws Exception {
        final Release release = MkReleaseTest.release();
        final Release.Smart smart = new Release.Smart(release);
        MatcherAssert.assertThat(
            smart.body(),
            Matchers.equalTo(this.value(release, "body"))
        );
View Full Code Here

Examples of com.jcabi.github.Release

     * Smart decorator returns created date.
     * @throws Exception If some problem inside
     */
    @Test
    public void canGetCreatedAt() throws Exception {
        final Release release = MkReleaseTest.release();
        final Release.Smart smart = new Release.Smart(release);
        MatcherAssert.assertThat(
            smart.createdAt(),
            Matchers.equalTo(new Github.Time(this.value(release, "created_at"))
                .date()
View Full Code Here

Examples of com.jcabi.github.Release

     * Smart decorator returns published date.
     * @throws Exception If some problem inside
     */
    @Test
    public void canGetPublichedAt() throws Exception {
        final Release release = MkReleaseTest.release();
        final Release.Smart smart = new Release.Smart(release);
        MatcherAssert.assertThat(
            smart.publishedAt(),
            Matchers.equalTo(
                new Github.Time(this.value(release, "published_at")).date()
View Full Code Here

Examples of com.jcabi.github.Release

     *
     * @throws Exception If a problem occurs.
     */
    @Test
    public void fetchesRelease() throws Exception {
        final Release rel = release();
        MatcherAssert.assertThat(
            rel.assets().release(),
            Matchers.is(rel)
        );
    }
View Full Code Here

Examples of com.liferay.portal.model.Release

public class ReleaseLocalManagerImpl implements ReleaseLocalManager {

  // Business methods

  public Release getRelease() throws PortalException, SystemException {
    Release release = null;

    try {
      release = ReleaseUtil.findByPrimaryKey(Release.DEFAULT_ID);
    }
    catch (NoSuchReleaseException nsre) {
      release = ReleaseUtil.create(Release.DEFAULT_ID);

      Date now = new Date();

      release.setCreateDate(now);
      release.setModifiedDate(now);

      ReleaseUtil.update(release);
    }

    return release;
View Full Code Here

Examples of com.puppetlabs.geppetto.forge.v2.model.Release

    List<Release> releases = moduleService.getReleases(moduleName.getOwner(), moduleName.getName(), null);
    if(releases.isEmpty())
      throw new FileNotFoundException("No releases found for module '" + moduleName + '\'');

    Release best = null;
    for(Release release : releases)
      if((best == null || release.getVersion().compareTo(best.getVersion()) > 0) &&
          (range == null || range.isIncluded(release.getVersion())))
        best = release;

    if(best == null)
      throw new FileNotFoundException("No releases matching '" + range + "' found for module '" + moduleName +
          '\'');

    if(!destinationIncludesTopFolder)
      // Use module name as the default
      destination = new File(destination, moduleName.getName());

    if(destination.exists()) {
      if(!force)
        throw new IOException("Destination folder is not empty: " + destination.getAbsolutePath());

      // Don't remove .project, .settings, .git, .svn, etc. if they are present.
      FileUtils.rmR(destination, FileUtils.DEFAULT_EXCLUDES);
    }

    File moduleFile = cache.retrieve(best.getFullName(), best.getVersion());

    // Unpack closes its input.
    TarUtils.unpack(new GZIPInputStream(new FileInputStream(moduleFile)), destination, true, null);
    return forgeUtil.loadJSONMetadata(new File(destination, METADATA_JSON_NAME));
  }
View Full Code Here

Examples of com.puppetlabs.geppetto.forge.v3.model.Release

    }
    return null;
  }

  public static Version getModuleVersion(Module module) {
    Release release = module.getCurrentRelease();
    return release == null
        ? null
        : release.getVersion();
  }
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.