"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.UninstallAppStep = void 0;
const MablStepV2_1 = require("../../MablStepV2");
class UninstallAppStep extends MablStepV2_1.MablStepV2 {
    static stepName = 'UninstallApp';
    static yamlMablScriptNames = [UninstallAppStep.stepName];
    static stepVersion = 2;
    constructor(descriptor) {
        super(UninstallAppStep.stepName, descriptor, 'uninstallApp');
    }
    stepDescription() {
        if (this.descriptor.appId) {
            return `Uninstall app - ${this.descriptor.appId}`;
        }
        return `Uninstall primary app under test`;
    }
    static fromYaml(_stepName, stepDescriptor) {
        return new UninstallAppStep(stepDescriptor);
    }
    static create(descriptor) {
        descriptor.id = descriptor.id ?? MablStepV2_1.MablStepV2.generateStepId();
        return new UninstallAppStep(descriptor);
    }
}
exports.UninstallAppStep = UninstallAppStep;
