Examples of RoleActor


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

    final Project anonProject = client.getProjectClient().getProject(ANONYMOUS_PROJECT_KEY).claim();
    final ProjectRole role = client.getProjectRolesRestClient().getRole(anonProject.getSelf(), 10000l).claim();
    assertNotNull(role);
    assertEquals("Users", role.getName());
    assertEquals("A project role that represents users in a project", role.getDescription());
    final RoleActor actor = Iterables.getOnlyElement(role.getActors());
    assertEquals("jira-users", actor.getDisplayName());
    assertEquals("atlassian-group-role-actor", actor.getType());
    assertEquals("jira-users", actor.getName());
    assertEquals(actor.getAvatarUri(), buildUserAvatarUri(null, 10083L, "16x16"));
  }
View Full Code Here

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

    final Project restrictedProject = client.getProjectClient().getProject(RESTRICTED_PROJECT_KEY).claim();
    final ProjectRole role = client.getProjectRolesRestClient().getRole(restrictedProject.getSelf(), 10000l).claim();
    assertNotNull(role);
    assertEquals("Users", role.getName());
    assertEquals("A project role that represents users in a project", role.getDescription());
    final RoleActor actor = Iterables.getOnlyElement(role.getActors());
    assertEquals("Administrator", actor.getDisplayName());
    assertEquals("atlassian-user-role-actor", actor.getType());
    assertEquals("admin", actor.getName());
    assertEquals(actor.getAvatarUri(), buildUserAvatarUri("admin", 10054L, "16x16"));
  }
View Full Code Here

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

    final URI roleURI = client.getProjectRolesRestClient().getRole(anonProject.getSelf(), 10000l).claim().getSelf();
    final ProjectRole role = client.getProjectRolesRestClient().getRole(roleURI).claim();
    assertNotNull(role);
    assertEquals("Users", role.getName());
    assertEquals("A project role that represents users in a project", role.getDescription());
    final RoleActor actor = Iterables.getOnlyElement(role.getActors());
    assertEquals("jira-users", actor.getDisplayName());
    assertEquals("atlassian-group-role-actor", actor.getType());
    assertEquals("jira-users", actor.getName());
    assertEquals(actor.getAvatarUri(), buildUserAvatarUri(null, 10083L, "16x16"));
  }
View Full Code Here

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

        }
    );
    assertThat(projectRolesWithoutSelf, containsInAnyOrder(
        new ProjectRole(10000l, null, "Users", "A project role that represents users in a project",
            ImmutableList.<RoleActor>of(
                new RoleActor(10062l, "jira-users", "atlassian-group-role-actor", "jira-users", buildUserAvatarUri(null, 10083L, "16x16"))
            )),
        new ProjectRole(10001l, null, "Developers", "A project role that represents developers in a project",
            ImmutableList.<RoleActor>of(
                new RoleActor(10061l, "jira-developers", "atlassian-group-role-actor", "jira-developers", buildUserAvatarUri(null, 10083L, "16x16")),
                new RoleActor(10063l, "My Test User", "atlassian-user-role-actor", "user", buildUserAvatarUri(null, 10082L, "16x16"))
            )),
        new ProjectRole(10002l, null, "Administrators", "A project role that represents administrators in a project",
            ImmutableList.<RoleActor>of(
                new RoleActor(10060l, "jira-administrators", "atlassian-group-role-actor", "jira-administrators", buildUserAvatarUri(null, 10083L, "16x16"))
            ))
    ));

    //noinspection unchecked
    Assert.assertThat(projectRoles, Matchers.containsInAnyOrder(
View Full Code Here

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

    final Project anonProject = client.getProjectClient().getProject(ANONYMOUS_PROJECT_KEY).claim();
    final ProjectRole role = client.getProjectRolesRestClient().getRole(anonProject.getSelf(), 10000l).claim();
    assertNotNull(role);
    assertEquals("Users", role.getName());
    assertEquals("A project role that represents users in a project", role.getDescription());
    final RoleActor actor = Iterables.getOnlyElement(role.getActors());
    assertEquals("jira-users", actor.getDisplayName());
    assertEquals("atlassian-group-role-actor", actor.getType());
    assertEquals("jira-users", actor.getName());
    assertEquals(actor.getAvatarUri(), buildUserAvatarUri(null, 10083L, "16x16"));
  }
View Full Code Here

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

    final Project restrictedProject = client.getProjectClient().getProject(RESTRICTED_PROJECT_KEY).claim();
    final ProjectRole role = client.getProjectRolesRestClient().getRole(restrictedProject.getSelf(), 10000l).claim();
    assertNotNull(role);
    assertEquals("Users", role.getName());
    assertEquals("A project role that represents users in a project", role.getDescription());
    final RoleActor actor = Iterables.getOnlyElement(role.getActors());
    assertEquals("Administrator", actor.getDisplayName());
    assertEquals("atlassian-user-role-actor", actor.getType());
    assertEquals("admin", actor.getName());
    assertEquals(actor.getAvatarUri(), buildUserAvatarUri("admin", 10054L, "16x16"));
  }
View Full Code Here

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

    final URI roleURI = client.getProjectRolesRestClient().getRole(anonProject.getSelf(), 10000l).claim().getSelf();
    final ProjectRole role = client.getProjectRolesRestClient().getRole(roleURI).claim();
    assertNotNull(role);
    assertEquals("Users", role.getName());
    assertEquals("A project role that represents users in a project", role.getDescription());
    final RoleActor actor = Iterables.getOnlyElement(role.getActors());
    assertEquals("jira-users", actor.getDisplayName());
    assertEquals("atlassian-group-role-actor", actor.getType());
    assertEquals("jira-users", actor.getName());
    assertEquals(actor.getAvatarUri(), buildUserAvatarUri(null, 10083L, "16x16"));
  }
View Full Code Here

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

        }
    );
    assertThat(projectRolesWithoutSelf, containsInAnyOrder(
        new ProjectRole(10000l, null, "Users", "A project role that represents users in a project",
            ImmutableList.<RoleActor>of(
                new RoleActor(10062l, "jira-users", "atlassian-group-role-actor", "jira-users", buildUserAvatarUri(null, 10083L, "16x16"))
            )),
        new ProjectRole(10001l, null, "Developers", "A project role that represents developers in a project",
            ImmutableList.<RoleActor>of(
                new RoleActor(10061l, "jira-developers", "atlassian-group-role-actor", "jira-developers", buildUserAvatarUri(null, 10083L, "16x16")),
                new RoleActor(10063l, "My Test User", "atlassian-user-role-actor", "user", buildUserAvatarUri(null, 10082L, "16x16"))
            )),
        new ProjectRole(10002l, null, "Administrators", "A project role that represents administrators in a project",
            ImmutableList.<RoleActor>of(
                new RoleActor(10060l, "jira-administrators", "atlassian-group-role-actor", "jira-administrators", buildUserAvatarUri(null, 10083L, "16x16"))
            ))
    ));

    assertNotNull(Iterables.find(projectRoles, new EntityHelper.AddressEndsWithPredicate("project/ANNON/role/10000")));
    assertNotNull(Iterables.find(projectRoles, new EntityHelper.AddressEndsWithPredicate("project/ANNON/role/10001")));
View Full Code Here

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

    final Project anonProject = client.getProjectClient().getProject(ANONYMOUS_PROJECT_KEY).claim();
    final ProjectRole role = client.getProjectRolesRestClient().getRole(anonProject.getSelf(), 10000l).claim();
    assertNotNull(role);
    assertEquals("Users", role.getName());
    assertEquals("A project role that represents users in a project", role.getDescription());
    final RoleActor actor = Iterables.getOnlyElement(role.getActors());
    assertEquals("jira-users", actor.getDisplayName());
    assertEquals("atlassian-group-role-actor", actor.getType());
    assertEquals("jira-users", actor.getName());
    assertEquals(jiraUri.resolve("/jira/secure/useravatar?size=small&avatarId=10083"), actor.getAvatarUri());
  }
View Full Code Here

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

    final Project restrictedProject = client.getProjectClient().getProject(RESTRICTED_PROJECT_KEY).claim();
    final ProjectRole role = client.getProjectRolesRestClient().getRole(restrictedProject.getSelf(), 10000l).claim();
    assertNotNull(role);
    assertEquals("Users", role.getName());
    assertEquals("A project role that represents users in a project", role.getDescription());
    final RoleActor actor = Iterables.getOnlyElement(role.getActors());
    assertEquals("Administrator", actor.getDisplayName());
    assertEquals("atlassian-user-role-actor", actor.getType());
    assertEquals("admin", actor.getName());
    assertEquals(jiraUri.resolve("/jira/secure/useravatar?size=small&ownerId=admin&avatarId=10054"), actor.getAvatarUri());
  }
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.