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

package com.azure.resourcemanager.networkfunction.generated;

import com.azure.core.util.BinaryData;
import com.azure.resourcemanager.networkfunction.fluent.models.AzureTrafficCollectorPropertiesFormat;
import com.azure.resourcemanager.networkfunction.models.ResourceReference;
import org.junit.jupiter.api.Test;

public final class AzureTrafficCollectorPropertiesFormatTests {
    @Test
    public void testDeserialize() {
        AzureTrafficCollectorPropertiesFormat model =
            BinaryData
                .fromString(
                    "{\"collectorPolicies\":[{\"id\":\"cjrwzoxxjtfellu\"}],\"virtualHub\":{\"id\":\"it\"},\"provisioningState\":\"Deleting\"}")
                .toObject(AzureTrafficCollectorPropertiesFormat.class);
    }

    @Test
    public void testSerialize() {
        AzureTrafficCollectorPropertiesFormat model =
            new AzureTrafficCollectorPropertiesFormat().withVirtualHub(new ResourceReference());
        model = BinaryData.fromObject(model).toObject(AzureTrafficCollectorPropertiesFormat.class);
    }
}
