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

package com.azure.resourcemanager.logic.generated;

import com.azure.core.util.BinaryData;
import com.azure.resourcemanager.logic.models.ApiResourceDefinitions;
import org.junit.jupiter.api.Assertions;

public final class ApiResourceDefinitionsTests {
    @org.junit.jupiter.api.Test
    public void testDeserialize() throws Exception {
        ApiResourceDefinitions model =
            BinaryData
                .fromString("{\"originalSwaggerUrl\":\"tzh\",\"modifiedSwaggerUrl\":\"glka\"}")
                .toObject(ApiResourceDefinitions.class);
        Assertions.assertEquals("tzh", model.originalSwaggerUrl());
        Assertions.assertEquals("glka", model.modifiedSwaggerUrl());
    }

    @org.junit.jupiter.api.Test
    public void testSerialize() throws Exception {
        ApiResourceDefinitions model =
            new ApiResourceDefinitions().withOriginalSwaggerUrl("tzh").withModifiedSwaggerUrl("glka");
        model = BinaryData.fromObject(model).toObject(ApiResourceDefinitions.class);
        Assertions.assertEquals("tzh", model.originalSwaggerUrl());
        Assertions.assertEquals("glka", model.modifiedSwaggerUrl());
    }
}
