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

package com.azure.resourcemanager.reservations.generated;

import com.azure.core.util.BinaryData;
import com.azure.resourcemanager.reservations.models.AvailableScopeRequest;
import com.azure.resourcemanager.reservations.models.AvailableScopeRequestProperties;
import java.util.Arrays;
import org.junit.jupiter.api.Assertions;

public final class AvailableScopeRequestTests {
    @org.junit.jupiter.api.Test
    public void testDeserialize() throws Exception {
        AvailableScopeRequest model =
            BinaryData
                .fromString("{\"properties\":{\"scopes\":[\"quvgjxpybczme\"]}}")
                .toObject(AvailableScopeRequest.class);
        Assertions.assertEquals("quvgjxpybczme", model.properties().scopes().get(0));
    }

    @org.junit.jupiter.api.Test
    public void testSerialize() throws Exception {
        AvailableScopeRequest model =
            new AvailableScopeRequest()
                .withProperties(new AvailableScopeRequestProperties().withScopes(Arrays.asList("quvgjxpybczme")));
        model = BinaryData.fromObject(model).toObject(AvailableScopeRequest.class);
        Assertions.assertEquals("quvgjxpybczme", model.properties().scopes().get(0));
    }
}
