Examples of CiServerType


Examples of org.netmelody.cieye.core.domain.CiServerType

                will(returnValue(viewWithJobsNamed("myJob")));
           
            never(contact).makeJsonRestCall(with(any(String.class)), with(JobDetail.class));
        }});
       
        final Feature feature = new Feature("myFeatureName", "myEndpoint", new CiServerType("JENKINS"));
        final TargetDigestGroup targets = spy.targetsConstituting(feature);
        context.assertIsSatisfied();
       
        context.checking(new Expectations() {{
            oneOf(contact).makeJsonRestCall(with(any(String.class)), with(JobDetail.class));
View Full Code Here

Examples of org.netmelody.cieye.core.domain.CiServerType

    private final ServiceLoadingRecordedForeignAgencies foreignAgencies = new ServiceLoadingRecordedForeignAgencies(new PluginDirectory(new File(".")));

    @Test public void
    loadsObeservationModules() {
        assertThat(foreignAgencies.agencyFor(new CiServerType("DEMO")), is(not(nullValue())));
        assertThat(foreignAgencies.agencyFor(new CiServerType("HUDSON")), is(not(nullValue())));
        assertThat(foreignAgencies.agencyFor(new CiServerType("JENKINS")), is(not(nullValue())));
        assertThat(foreignAgencies.agencyFor(new CiServerType("TEAMCITY")), is(not(nullValue())));
    }
View Full Code Here

Examples of org.netmelody.cieye.core.domain.CiServerType

    }

    @Test public void
    handlesRequestsForAnUnknownAgency() {
        try {
            foreignAgencies.agencyFor(new CiServerType("SAUSAGE"));
            fail("Expected an IllegalStateException");
        }
        catch (Exception e) {
            assertThat(e.getMessage(), containsString("No CI Observation Module for SAUSAGE"));
        }
View Full Code Here

Examples of org.netmelody.cieye.core.domain.CiServerType

    populatesLandscapeWithFeatures() throws Exception {
        final File views = testFolder.newFile("views.txt");
        FileUtils.copyInputStreamToFile(RecordedObservationTargetsTest.class.getResourceAsStream("testviews.txt"), views);
        final RecordedObservationTargets targets = new RecordedObservationTargets(new SettingsFile(views));
        final Collection<Feature> features = targets.landscapes().landscapeNamed("Landscape- 2").features();
        assertThat(features, contains(new Feature("Jenkins 1", "http://jenkinsurl", new CiServerType("JENKINS")),
                                      new Feature("Hudson 1", "http://hudsonurl", new CiServerType("HUDSON")),
                                      new Feature("TeamCity 1", "http://teamcityurl", new CiServerType("TEAMCITY")),
                                      new Feature("", "http://allurl", new CiServerType("JENKINS")),
                                      new Feature("TeamCity 2", "http://tcsecure", new CiServerType("TEAMCITY"), "user", "pass")));
    }
View Full Code Here

Examples of org.netmelody.cieye.core.domain.CiServerType

        assertThat(targets.landscapes().landscapeNamed("CI-eye Demo"), is(not(nullValue())));
        assertThat(targets.landscapes().landscapeNamed("Public Live"), is(not(nullValue())));
       
        final Collection<Feature> features = targets.landscapes().landscapeNamed("Public Live").features();
        assertThat(features, contains(new Feature("Jenkins core", "http://ci.jenkins-ci.org", new CiServerType("JENKINS")),
                                      new Feature("Main (trunk, branches, and alternative builds)", "http://hudson.magnolia-cms.com", new CiServerType("HUDSON")),
                                      new Feature("Apache Ivy", "http://teamcity.jetbrains.com", new CiServerType("TEAMCITY")),
                                      new Feature("CI-Eye", "http://teamcity.codebetter.com", new CiServerType("TEAMCITY"))));
    }
View Full Code Here

Examples of org.netmelody.cieye.core.domain.CiServerType

            allowing(contact).privileged(); will(returnValue(false));
        }});
       
        final TeamCitySpy spy = new TeamCitySpy("myEndpoint", detective, contact);
       
        final TargetDigestGroup result = spy.targetsConstituting(new Feature("", "myOtherEndpoint", new CiServerType("TEAMCITY")));
       
        assertThat(result, is(Matchers.<TargetDigest>emptyIterable()));
    }
View Full Code Here

Examples of org.netmelody.cieye.core.domain.CiServerType

        context.checking(new Expectations() {{
            oneOf(contact).makeJsonRestCall(with(Matchers.startsWith("myEndpoint/guestAuth")), with(BuildTypes.class));
                will(returnValue(new BuildTypes()));
        }});
       
        spy.targetsConstituting(new Feature("", "myEndpoint", new CiServerType("TEAMCITY")));
       
        context.assertIsSatisfied();
    }
View Full Code Here

Examples of org.netmelody.cieye.core.domain.CiServerType

        context.checking(new Expectations() {{
            oneOf(contact).makeJsonRestCall(with(Matchers.startsWith("myEndpoint/httpAuth")), with(BuildTypes.class));
            will(returnValue(new BuildTypes()));
        }});
       
        spy.targetsConstituting(new Feature("", "myEndpoint", new CiServerType("TEAMCITY")));
       
        context.assertIsSatisfied();
    }
View Full Code Here

Examples of org.netmelody.cieye.core.domain.CiServerType

                will(returnValue(projectNamed("myTarget")));
           
            never(contact).makeJsonRestCall(with(any(String.class)), with(BuildTypeDetail.class));
        }});
       
        final TargetDigestGroup digest = spy.targetsConstituting(new Feature("myFeatureName", "myEndpoint", new CiServerType("TEAMCITY")));
        context.assertIsSatisfied();
       
        context.checking(new Expectations() {{
            oneOf(contact).makeJsonRestCall(with(any(String.class)), with(BuildTypeDetail.class));
                will(returnValue(buildTypeDetail()));
View Full Code Here

Examples of org.netmelody.cieye.core.domain.CiServerType

        assertThat(new JsonTranslator().toJson(group), is("{\"landscapes\":[]}"));
    }
   
    @Test public void
    translatesToAppropriateJsonRepresentation() {
        final LandscapeGroup group = new LandscapeGroup(newArrayList(new Landscape("L1", new Feature("F11", "E11", new CiServerType("T11")),
                                                                                         new Feature("F12", "E12", new CiServerType("T12"))),
                                                                     new Landscape("L2", new Feature("F21", "E21", new CiServerType("T21")),
                                                                                         new Feature("F22", "E22", new CiServerType("T22")))));
       
        assertThat(new JsonTranslator().toJson(group), is("{\"landscapes\":[" +
                                                              "{\"name\":\"L1\"}," +
                                                              "{\"name\":\"L2\"}" +
                                                          "]}"));
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.