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

package com.azure.resourcemanager.storagemover.generated;

import com.azure.core.util.BinaryData;
import com.azure.resourcemanager.storagemover.models.AzureStorageBlobContainerEndpointProperties;
import org.junit.jupiter.api.Assertions;

public final class AzureStorageBlobContainerEndpointPropertiesTests {
    @org.junit.jupiter.api.Test
    public void testDeserialize() throws Exception {
        AzureStorageBlobContainerEndpointProperties model =
            BinaryData
                .fromString(
                    "{\"endpointType\":\"AzureStorageBlobContainer\",\"storageAccountResourceId\":\"lpbuxwgipwhonowk\",\"blobContainerName\":\"shwankixzbinje\",\"description\":\"ttmrywnuzoqf\",\"provisioningState\":\"Succeeded\"}")
                .toObject(AzureStorageBlobContainerEndpointProperties.class);
        Assertions.assertEquals("ttmrywnuzoqf", model.description());
        Assertions.assertEquals("lpbuxwgipwhonowk", model.storageAccountResourceId());
        Assertions.assertEquals("shwankixzbinje", model.blobContainerName());
    }

    @org.junit.jupiter.api.Test
    public void testSerialize() throws Exception {
        AzureStorageBlobContainerEndpointProperties model =
            new AzureStorageBlobContainerEndpointProperties()
                .withDescription("ttmrywnuzoqf")
                .withStorageAccountResourceId("lpbuxwgipwhonowk")
                .withBlobContainerName("shwankixzbinje");
        model = BinaryData.fromObject(model).toObject(AzureStorageBlobContainerEndpointProperties.class);
        Assertions.assertEquals("ttmrywnuzoqf", model.description());
        Assertions.assertEquals("lpbuxwgipwhonowk", model.storageAccountResourceId());
        Assertions.assertEquals("shwankixzbinje", model.blobContainerName());
    }
}
