// 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.NameDescriptionObject;
import org.junit.jupiter.api.Assertions;

public final class NameDescriptionObjectTests {
    @org.junit.jupiter.api.Test
    public void testDeserialize() throws Exception {
        NameDescriptionObject model =
            BinaryData
                .fromString("{\"name\":\"ounqecano\",\"description\":\"upfh\"}")
                .toObject(NameDescriptionObject.class);
        Assertions.assertEquals("ounqecano", model.name());
        Assertions.assertEquals("upfh", model.description());
    }

    @org.junit.jupiter.api.Test
    public void testSerialize() throws Exception {
        NameDescriptionObject model = new NameDescriptionObject().withName("ounqecano").withDescription("upfh");
        model = BinaryData.fromObject(model).toObject(NameDescriptionObject.class);
        Assertions.assertEquals("ounqecano", model.name());
        Assertions.assertEquals("upfh", model.description());
    }
}
