// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.security.generated;

import com.azure.core.util.BinaryData;
import com.azure.resourcemanager.security.models.GcpOrganizationalDataMember;
import org.junit.jupiter.api.Assertions;

public final class GcpOrganizationalDataMemberTests {
    @org.junit.jupiter.api.Test
    public void testDeserialize() throws Exception {
        GcpOrganizationalDataMember model =
            BinaryData
                .fromString(
                    "{\"organizationMembershipType\":\"Member\",\"parentHierarchyId\":\"atxtjrrlkmdskjhh\",\"managementProjectNumber\":\"lajfoxcxscvslxlh\"}")
                .toObject(GcpOrganizationalDataMember.class);
        Assertions.assertEquals("atxtjrrlkmdskjhh", model.parentHierarchyId());
        Assertions.assertEquals("lajfoxcxscvslxlh", model.managementProjectNumber());
    }

    @org.junit.jupiter.api.Test
    public void testSerialize() throws Exception {
        GcpOrganizationalDataMember model =
            new GcpOrganizationalDataMember()
                .withParentHierarchyId("atxtjrrlkmdskjhh")
                .withManagementProjectNumber("lajfoxcxscvslxlh");
        model = BinaryData.fromObject(model).toObject(GcpOrganizationalDataMember.class);
        Assertions.assertEquals("atxtjrrlkmdskjhh", model.parentHierarchyId());
        Assertions.assertEquals("lajfoxcxscvslxlh", model.managementProjectNumber());
    }
}
