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

package com.azure.resourcemanager.databoxedge.generated;

import com.azure.core.util.BinaryData;
import com.azure.resourcemanager.databoxedge.fluent.models.UploadCertificateResponseInner;
import com.azure.resourcemanager.databoxedge.models.AuthenticationType;
import org.junit.jupiter.api.Assertions;

public final class UploadCertificateResponseInnerTests {
    @org.junit.jupiter.api.Test
    public void testDeserialize() throws Exception {
        UploadCertificateResponseInner model =
            BinaryData
                .fromString(
                    "{\"authType\":\"Invalid\",\"resourceId\":\"asipqiio\",\"aadAuthority\":\"uqerpqlpqwc\",\"aadTenantId\":\"uqgbdbutauvfbt\",\"servicePrincipalClientId\":\"whhmhykojo\",\"servicePrincipalObjectId\":\"fnndl\",\"azureManagementEndpointAudience\":\"chkoymkcdyh\",\"aadAudience\":\"kkpwdreqnovvq\"}")
                .toObject(UploadCertificateResponseInner.class);
        Assertions.assertEquals(AuthenticationType.INVALID, model.authType());
    }

    @org.junit.jupiter.api.Test
    public void testSerialize() throws Exception {
        UploadCertificateResponseInner model =
            new UploadCertificateResponseInner().withAuthType(AuthenticationType.INVALID);
        model = BinaryData.fromObject(model).toObject(UploadCertificateResponseInner.class);
        Assertions.assertEquals(AuthenticationType.INVALID, model.authType());
    }
}
