Examples of IssueInput


Examples of com.atlassian.jira.rest.client.api.domain.input.IssueInput

    // build issue input
    final String summary = "My new issue!";

    // create
    final IssueInput issueInput = new IssueInputBuilder(project, issueType, summary).build();
    final BasicIssue basicCreatedIssue = issueClient.createIssue(issueInput).claim();
    assertNotNull(basicCreatedIssue.getKey());

    // get issue and check if everything was set as we expected
    final Issue createdIssue = issueClient.getIssue(basicCreatedIssue.getKey()).claim();
View Full Code Here

Examples of com.atlassian.jira.rest.client.api.domain.input.IssueInput

    final IssueRestClient issueClient = client.getIssueClient();

    thrown.expect(RestClientException.class);
    thrown.expectMessage("You must specify a summary of the issue.");

    final IssueInput issueInput = new IssueInputBuilder("TST", 1L).build();
    issueClient.createIssue(issueInput).claim();
  }
View Full Code Here

Examples of com.atlassian.jira.rest.client.api.domain.input.IssueInput

    final IssueRestClient issueClient = client.getIssueClient();

    thrown.expect(RestClientException.class);
    thrown.expectMessage("project is required");

    final IssueInput issueInput = new IssueInputBuilder("BAD", 1L, "Should fail").build();
    issueClient.createIssue(issueInput).claim();
  }
View Full Code Here

Examples of com.atlassian.jira.rest.client.api.domain.input.IssueInput

    final IssueRestClient issueClient = client.getIssueClient();

    thrown.expect(RestClientException.class);
    thrown.expectMessage("valid issue type is required");

    final IssueInput issueInput = new IssueInputBuilder("TST", 666L, "Should fail").build();
    issueClient.createIssue(issueInput).claim();
  }
View Full Code Here

Examples of com.atlassian.jira.rest.client.domain.input.IssueInput

public class IssueInputJsonGeneratorTest {

  @Test
  public void testGenerate() throws Exception {
    final IssueInputJsonGenerator generator = new IssueInputJsonGenerator();
    final IssueInput issueInput = IssueInput.createWithFields(
        new FieldInput("string", "String value"),
        new FieldInput("integer", 1),
        new FieldInput("long", 1L),
        new FieldInput("complex", new ComplexIssueInputFieldValue(ImmutableMap.<String, Object>of(
            "string", "string",
View Full Code Here

Examples of com.atlassian.jira.rest.client.domain.input.IssueInput

  }

  @Test
  public void testGenerateWithEmptyInput() throws Exception {
    final IssueInputJsonGenerator generator = new IssueInputJsonGenerator();
    final IssueInput issueInput = new IssueInput(Maps.<String, FieldInput>newHashMap());

    final JSONObject expected = ResourceUtil.getJsonObjectFromResource("/json/issueInput/empty.json");
    final JSONObject actual = generator.generate(issueInput);
    assertThat(expected, JSONObjectMatcher.isEqual(actual));
  }
View Full Code Here

Examples of com.atlassian.jira.rest.client.domain.input.IssueInput

  }

  @Test
  public void testGenerateWithNullInput() throws Exception {
    final IssueInputJsonGenerator generator = new IssueInputJsonGenerator();
    final IssueInput issueInput = null;

    final JSONObject expected = ResourceUtil.getJsonObjectFromResource("/json/issueInput/empty.json");
    final JSONObject actual = generator.generate(issueInput);
    assertThat(expected, JSONObjectMatcher.isEqual(actual));
  }
View Full Code Here

Examples of com.atlassian.jira.rest.client.domain.input.IssueInput

    // build issue input
    final String summary = "My new issue!";

    // create
    final IssueInput issueInput = new IssueInputBuilder(project, issueType, summary).build();
    final BasicIssue basicCreatedIssue = issueClient.createIssue(issueInput, pm);
    assertNotNull(basicCreatedIssue.getKey());

    // get issue and check if everything was set as we expected
    final Issue createdIssue = issueClient.getIssue(basicCreatedIssue.getKey(), pm);
View Full Code Here

Examples of com.atlassian.jira.rest.client.domain.input.IssueInput

    final IssueRestClient issueClient = client.getIssueClient();

    thrown.expect(RestClientException.class);
    thrown.expectMessage("You must specify a summary of the issue.");

    final IssueInput issueInput = new IssueInputBuilder("TST", 1L).build();
    issueClient.createIssue(issueInput, pm);
  }
View Full Code Here

Examples of com.atlassian.jira.rest.client.domain.input.IssueInput

    final IssueRestClient issueClient = client.getIssueClient();

    thrown.expect(RestClientException.class);
    thrown.expectMessage("project is required");

    final IssueInput issueInput = new IssueInputBuilder("BAD", 1L, "Should fail").build();
    issueClient.createIssue(issueInput, pm);
  }
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.