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