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

package com.azure.resourcemanager.mediaservices.generated;

import com.azure.core.util.BinaryData;
import com.azure.resourcemanager.mediaservices.models.ArmStreamingEndpointCapacity;
import org.junit.jupiter.api.Assertions;

public final class ArmStreamingEndpointCapacityTests {
    @org.junit.jupiter.api.Test
    public void testDeserialize() throws Exception {
        ArmStreamingEndpointCapacity model =
            BinaryData
                .fromString("{\"scaleType\":\"vh\",\"default\":55110922,\"minimum\":1149174942,\"maximum\":751350709}")
                .toObject(ArmStreamingEndpointCapacity.class);
        Assertions.assertEquals(55110922, model.defaultProperty());
        Assertions.assertEquals(1149174942, model.minimum());
        Assertions.assertEquals(751350709, model.maximum());
    }

    @org.junit.jupiter.api.Test
    public void testSerialize() throws Exception {
        ArmStreamingEndpointCapacity model =
            new ArmStreamingEndpointCapacity()
                .withDefaultProperty(55110922)
                .withMinimum(1149174942)
                .withMaximum(751350709);
        model = BinaryData.fromObject(model).toObject(ArmStreamingEndpointCapacity.class);
        Assertions.assertEquals(55110922, model.defaultProperty());
        Assertions.assertEquals(1149174942, model.minimum());
        Assertions.assertEquals(751350709, model.maximum());
    }
}
