Package org.sonar.api.resources

Examples of org.sonar.api.resources.ResourceTypeTree


import static org.fest.assertions.Assertions.assertThat;

public class DefaultResourceTypesTest {
  @Test
  public void provide_types() {
    ResourceTypeTree tree = new DefaultResourceTypes().provide();

    assertThat(tree.getTypes()).hasSize(7);
    assertThat(tree.getChildren(Qualifiers.PROJECT)).containsExactly(Qualifiers.MODULE);
  }
View Full Code Here


    assertThat(tree.getChildren(Qualifiers.PROJECT)).containsExactly(Qualifiers.MODULE);
  }

  @Test
  public void projects_should_be_available_for_global_widgets() {
    ResourceTypeTree tree = new DefaultResourceTypes().provide();

    ResourceType projectResourceType = tree.getTypes().get(0);

    assertThat(projectResourceType.getQualifier()).isEqualTo(Qualifiers.PROJECT);
    assertThat(projectResourceType.getBooleanProperty("supportsGlobalDashboards")).isTrue();
  }
View Full Code Here

TOP

Related Classes of org.sonar.api.resources.ResourceTypeTree

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.