Package com.atlassian.jira.rest.client.api.domain

Examples of com.atlassian.jira.rest.client.api.domain.BasicComponent


    // grab the first component
    final Iterable<Object> allowedValuesForComponents = issueType.getField(IssueFieldId.COMPONENTS_FIELD).getAllowedValues();
    assertNotNull(allowedValuesForComponents);
    assertTrue(allowedValuesForComponents.iterator().hasNext());
    final BasicComponent component = (BasicComponent) allowedValuesForComponents.iterator().next();

    // grab the first priority
    final Iterable<Object> allowedValuesForPriority = issueType.getField(IssueFieldId.PRIORITY_FIELD).getAllowedValues();
    assertNotNull(allowedValuesForPriority);
    assertTrue(allowedValuesForPriority.iterator().hasNext());
View Full Code Here


public class ComponentJsonParserTest {
  @Test
  public void testParseBasicComponent() throws Exception {
    BasicComponentJsonParser parser = new BasicComponentJsonParser();
    final BasicComponent component = parser.parse(ResourceUtil.getJsonObjectFromResource("/json/component/basic-valid.json"));
    Assert.assertEquals(new URI("http://localhost:8090/jira/rest/api/latest/component/10000"), component.getSelf());
    Assert.assertEquals("Component A", component.getName());
    Assert.assertEquals("this is some description of component A", component.getDescription());
  }
View Full Code Here

  }

  @Test
  public void testParseBasicComponentWithNoDescription() throws Exception {
    BasicComponentJsonParser parser = new BasicComponentJsonParser();
    final BasicComponent component = parser.parse(ResourceUtil
        .getJsonObjectFromResource("/json/component/basic-no-description-valid.json"));
    Assert.assertEquals(new URI("http://localhost:8090/jira/rest/api/latest/component/10000"), component.getSelf());
    Assert.assertEquals("Component A", component.getName());
    Assert.assertNull(component.getDescription());
  }
View Full Code Here

TOP

Related Classes of com.atlassian.jira.rest.client.api.domain.BasicComponent

Copyright © 2018 www.massapicom. 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.