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

package com.azure.resourcemanager.synapse.generated;

import com.azure.core.util.BinaryData;
import com.azure.resourcemanager.synapse.models.AutoScaleProperties;
import org.junit.jupiter.api.Assertions;

public final class AutoScalePropertiesTests {
    @org.junit.jupiter.api.Test
    public void testDeserialize() throws Exception {
        AutoScaleProperties model =
            BinaryData
                .fromString("{\"minNodeCount\":1303035802,\"enabled\":true,\"maxNodeCount\":111762942}")
                .toObject(AutoScaleProperties.class);
        Assertions.assertEquals(1303035802, model.minNodeCount());
        Assertions.assertEquals(true, model.enabled());
        Assertions.assertEquals(111762942, model.maxNodeCount());
    }

    @org.junit.jupiter.api.Test
    public void testSerialize() throws Exception {
        AutoScaleProperties model =
            new AutoScaleProperties().withMinNodeCount(1303035802).withEnabled(true).withMaxNodeCount(111762942);
        model = BinaryData.fromObject(model).toObject(AutoScaleProperties.class);
        Assertions.assertEquals(1303035802, model.minNodeCount());
        Assertions.assertEquals(true, model.enabled());
        Assertions.assertEquals(111762942, model.maxNodeCount());
    }
}
