"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getExpectedDeploymentType = getExpectedDeploymentType;
exports.isDeploymentMatchByType = isDeploymentMatchByType;
const mablApi_1 = require("../mablApi");
function getExpectedDeploymentType(testType) {
    switch (testType) {
        case mablApi_1.TestTypeEnum.Api:
            return mablApi_1.Deployment.DeploymentTypeEnum.Api;
        case mablApi_1.TestTypeEnum.Mobile:
            return mablApi_1.Deployment.DeploymentTypeEnum.MobileApplication;
        default:
            return mablApi_1.Deployment.DeploymentTypeEnum.WebApplication;
    }
}
function isDeploymentMatchByType(deployment, expectedDeploymentType) {
    return (deployment.deployment_type === expectedDeploymentType ||
        (!deployment.deployment_type &&
            expectedDeploymentType === mablApi_1.Deployment.DeploymentTypeEnum.WebApplication));
}
