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

package com.azure.resourcemanager.paloaltonetworks.ngfw.generated;

import com.azure.core.util.BinaryData;
import com.azure.resourcemanager.paloaltonetworks.ngfw.models.IpAddressSpace;
import org.junit.jupiter.api.Assertions;

public final class IpAddressSpaceTests {
    @org.junit.jupiter.api.Test
    public void testDeserialize() throws Exception {
        IpAddressSpace model =
            BinaryData
                .fromString("{\"resourceId\":\"ypbsfgytguslfead\",\"addressSpace\":\"gq\"}")
                .toObject(IpAddressSpace.class);
        Assertions.assertEquals("ypbsfgytguslfead", model.resourceId());
        Assertions.assertEquals("gq", model.addressSpace());
    }

    @org.junit.jupiter.api.Test
    public void testSerialize() throws Exception {
        IpAddressSpace model = new IpAddressSpace().withResourceId("ypbsfgytguslfead").withAddressSpace("gq");
        model = BinaryData.fromObject(model).toObject(IpAddressSpace.class);
        Assertions.assertEquals("ypbsfgytguslfead", model.resourceId());
        Assertions.assertEquals("gq", model.addressSpace());
    }
}
