Examples of GithubProjectProperty


Examples of com.coravy.hudson.plugins.github.GithubProjectProperty

    ConcurrentMap<Integer, GhprbPullRequest> pulls = new ConcurrentHashMap<Integer, GhprbPullRequest>(1);
    pulls.put(pullId, pullRequest);
    Map<String, ConcurrentMap<Integer, GhprbPullRequest>> jobs = new HashMap<String, ConcurrentMap<Integer, GhprbPullRequest>>(1);
    jobs.put("project", pulls);

    GithubProjectProperty projectProperty = new GithubProjectProperty("https://github.com/jenkinsci/ghprb-plugin");
    DescriptorImpl descriptor = trigger.getDescriptor();
   
    PrintStream logger = mock(PrintStream.class);

       
View Full Code Here

Examples of com.coravy.hudson.plugins.github.GithubProjectProperty

                "user", "user", "", "*/1 * * * *", "retest this please", false, false, false, false, null, null, false
        );
        given(commitPointer.getSha()).willReturn("sha");
        JSONObject jsonObject = provideConfiguration();
        jenkinsRule.getPluginManager().getPlugin(GHPRB_PLUGIN_NAME).getPlugin().configure(null, jsonObject);
        project.addProperty(new GithubProjectProperty("https://github.com/user/dropwizard"));
         given(ghPullRequest.getNumber()).willReturn(1);

        // Creating spy on ghprb, configuring repo
        Ghprb ghprb = spy(trigger.createGhprb(project));
        doReturn(ghprbGitHub).when(ghprb).getGitHub();
View Full Code Here

Examples of com.coravy.hudson.plugins.github.GithubProjectProperty

        );
        given(commitPointer.getSha()).willReturn("sha").willReturn("sha").willReturn("newOne").willReturn("newOne");
        given(ghPullRequest.getComments()).willReturn(Lists.<GHIssueComment>newArrayList());
        JSONObject jsonObject = provideConfiguration();
        jenkinsRule.getPluginManager().getPlugin(GHPRB_PLUGIN_NAME).getPlugin().configure(null, jsonObject);
        project.addProperty(new GithubProjectProperty("https://github.com/user/dropwizard"));
        given(ghPullRequest.getNumber()).willReturn(2).willReturn(2).willReturn(3).willReturn(3);
        Ghprb ghprb = spy(trigger.createGhprb(project));
        doReturn(ghprbGitHub).when(ghprb).getGitHub();
        trigger.start(project, true);
        trigger.setHelper(ghprb);
View Full Code Here

Examples of com.coravy.hudson.plugins.github.GithubProjectProperty

        given(comment.getUser()).willReturn(ghUser);
        given(ghPullRequest.getComments()).willReturn(newArrayList(comment));
        given(ghPullRequest.getNumber()).willReturn(5).willReturn(5).willReturn(6).willReturn(6);
        JSONObject jsonObject = provideConfiguration();
        jenkinsRule.getPluginManager().getPlugin(GHPRB_PLUGIN_NAME).getPlugin().configure(null, jsonObject);
        project.addProperty(new GithubProjectProperty("https://github.com/user/dropwizard"));

        Ghprb ghprb = spy(trigger.createGhprb(project));
        doReturn(ghprbGitHub).when(ghprb).getGitHub();
        trigger.start(project, true);
        trigger.setHelper(ghprb);
View Full Code Here

Examples of com.coravy.hudson.plugins.github.GithubProjectProperty

    private GhprbBuilds builds;

    public Ghprb(AbstractProject<?, ?> project, GhprbTrigger trigger, ConcurrentMap<Integer, GhprbPullRequest> pulls) {
        this.project = project;

        final GithubProjectProperty ghpp = project.getProperty(GithubProjectProperty.class);
        if (ghpp == null || ghpp.getProjectUrl() == null) {
            throw new IllegalStateException("A GitHub project url is required.");
        }
        String baseUrl = ghpp.getProjectUrl().baseUrl();
        Matcher m = githubUserRepoPattern.matcher(baseUrl);
        if (!m.matches()) {
            throw new IllegalStateException(String.format("Invalid GitHub project url: %s", baseUrl));
        }
        final String user = m.group(2);
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.