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

package com.azure.resourcemanager.loadtesting.generated;

import com.azure.core.util.BinaryData;
import com.azure.resourcemanager.loadtesting.fluent.models.CheckQuotaAvailabilityResponseProperties;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;

public final class CheckQuotaAvailabilityResponsePropertiesTests {
    @Test
    public void testDeserialize() throws Exception {
        CheckQuotaAvailabilityResponseProperties model =
            BinaryData
                .fromString("{\"isAvailable\":false,\"availabilityStatus\":\"sy\"}")
                .toObject(CheckQuotaAvailabilityResponseProperties.class);
        Assertions.assertEquals(false, model.isAvailable());
        Assertions.assertEquals("sy", model.availabilityStatus());
    }

    @Test
    public void testSerialize() throws Exception {
        CheckQuotaAvailabilityResponseProperties model =
            new CheckQuotaAvailabilityResponseProperties().withIsAvailable(false).withAvailabilityStatus("sy");
        model = BinaryData.fromObject(model).toObject(CheckQuotaAvailabilityResponseProperties.class);
        Assertions.assertEquals(false, model.isAvailable());
        Assertions.assertEquals("sy", model.availabilityStatus());
    }
}
