Search in sources :

Example 1 with ServerOrganization

use of org.sonarsource.sonarlint.core.serverapi.organization.ServerOrganization in project sonarlint-core by SonarSource.

the class DefaultRemoteOrganizationTests method testRoundTrip.

@Test
void testRoundTrip() {
    var org = Organization.newBuilder().setName("name").setKey("key").setDescription("desc").build();
    ServerOrganization remoteOrg = new DefaultRemoteOrganization(org);
    assertThat(remoteOrg.getKey()).isEqualTo("key");
    assertThat(remoteOrg.getName()).isEqualTo("name");
    assertThat(remoteOrg.getDescription()).isEqualTo("desc");
}
Also used : ServerOrganization(org.sonarsource.sonarlint.core.serverapi.organization.ServerOrganization) DefaultRemoteOrganization(org.sonarsource.sonarlint.core.serverapi.organization.DefaultRemoteOrganization) Test(org.junit.jupiter.api.Test)

Aggregations

Test (org.junit.jupiter.api.Test)1 DefaultRemoteOrganization (org.sonarsource.sonarlint.core.serverapi.organization.DefaultRemoteOrganization)1 ServerOrganization (org.sonarsource.sonarlint.core.serverapi.organization.ServerOrganization)1