task-pipeliner 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.ko.md +1034 -0
- package/README.md +1031 -0
- package/dist/cli/index.d.ts +19 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +147 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/cli/prompts.d.ts +48 -0
- package/dist/cli/prompts.d.ts.map +1 -0
- package/dist/cli/prompts.js +75 -0
- package/dist/cli/prompts.js.map +1 -0
- package/dist/cli/ui.d.ts +39 -0
- package/dist/cli/ui.d.ts.map +1 -0
- package/dist/cli/ui.js +84 -0
- package/dist/cli/ui.js.map +1 -0
- package/dist/core/__tests__/actual-execution.test.d.ts +2 -0
- package/dist/core/__tests__/actual-execution.test.d.ts.map +1 -0
- package/dist/core/__tests__/actual-execution.test.js +140 -0
- package/dist/core/__tests__/actual-execution.test.js.map +1 -0
- package/dist/core/__tests__/base-dir.test.d.ts +2 -0
- package/dist/core/__tests__/base-dir.test.d.ts.map +1 -0
- package/dist/core/__tests__/base-dir.test.js +146 -0
- package/dist/core/__tests__/base-dir.test.js.map +1 -0
- package/dist/core/__tests__/built-code-execution.test.d.ts +2 -0
- package/dist/core/__tests__/built-code-execution.test.d.ts.map +1 -0
- package/dist/core/__tests__/built-code-execution.test.js +48 -0
- package/dist/core/__tests__/built-code-execution.test.js.map +1 -0
- package/dist/core/__tests__/choose-as-var-condition.test.d.ts +2 -0
- package/dist/core/__tests__/choose-as-var-condition.test.d.ts.map +1 -0
- package/dist/core/__tests__/choose-as-var-condition.test.js +308 -0
- package/dist/core/__tests__/choose-as-var-condition.test.js.map +1 -0
- package/dist/core/__tests__/cli-integration.test.d.ts +2 -0
- package/dist/core/__tests__/cli-integration.test.d.ts.map +1 -0
- package/dist/core/__tests__/cli-integration.test.js +83 -0
- package/dist/core/__tests__/cli-integration.test.js.map +1 -0
- package/dist/core/__tests__/comprehensive-basic-yaml.test.d.ts +2 -0
- package/dist/core/__tests__/comprehensive-basic-yaml.test.d.ts.map +1 -0
- package/dist/core/__tests__/comprehensive-basic-yaml.test.js +111 -0
- package/dist/core/__tests__/comprehensive-basic-yaml.test.js.map +1 -0
- package/dist/core/__tests__/condition-evaluator.test.d.ts +2 -0
- package/dist/core/__tests__/condition-evaluator.test.d.ts.map +1 -0
- package/dist/core/__tests__/condition-evaluator.test.js +170 -0
- package/dist/core/__tests__/condition-evaluator.test.js.map +1 -0
- package/dist/core/__tests__/debug-basic-yaml.test.d.ts +2 -0
- package/dist/core/__tests__/debug-basic-yaml.test.d.ts.map +1 -0
- package/dist/core/__tests__/debug-basic-yaml.test.js +128 -0
- package/dist/core/__tests__/debug-basic-yaml.test.js.map +1 -0
- package/dist/core/__tests__/example-files.test.d.ts +2 -0
- package/dist/core/__tests__/example-files.test.d.ts.map +1 -0
- package/dist/core/__tests__/example-files.test.js +200 -0
- package/dist/core/__tests__/example-files.test.js.map +1 -0
- package/dist/core/__tests__/executor-choice-integration.test.d.ts +2 -0
- package/dist/core/__tests__/executor-choice-integration.test.d.ts.map +1 -0
- package/dist/core/__tests__/executor-choice-integration.test.js +171 -0
- package/dist/core/__tests__/executor-choice-integration.test.js.map +1 -0
- package/dist/core/__tests__/executor-choice.test.d.ts +2 -0
- package/dist/core/__tests__/executor-choice.test.d.ts.map +1 -0
- package/dist/core/__tests__/executor-choice.test.js +174 -0
- package/dist/core/__tests__/executor-choice.test.js.map +1 -0
- package/dist/core/__tests__/executor-parallel.test.d.ts +2 -0
- package/dist/core/__tests__/executor-parallel.test.d.ts.map +1 -0
- package/dist/core/__tests__/executor-parallel.test.js +136 -0
- package/dist/core/__tests__/executor-parallel.test.js.map +1 -0
- package/dist/core/__tests__/executor-prompt.test.d.ts +2 -0
- package/dist/core/__tests__/executor-prompt.test.d.ts.map +1 -0
- package/dist/core/__tests__/executor-prompt.test.js +149 -0
- package/dist/core/__tests__/executor-prompt.test.js.map +1 -0
- package/dist/core/__tests__/executor-real-scenario.test.d.ts +2 -0
- package/dist/core/__tests__/executor-real-scenario.test.d.ts.map +1 -0
- package/dist/core/__tests__/executor-real-scenario.test.js +169 -0
- package/dist/core/__tests__/executor-real-scenario.test.js.map +1 -0
- package/dist/core/__tests__/file-condition.test.d.ts +2 -0
- package/dist/core/__tests__/file-condition.test.d.ts.map +1 -0
- package/dist/core/__tests__/file-condition.test.js +182 -0
- package/dist/core/__tests__/file-condition.test.js.map +1 -0
- package/dist/core/__tests__/final-verification.test.d.ts +2 -0
- package/dist/core/__tests__/final-verification.test.d.ts.map +1 -0
- package/dist/core/__tests__/final-verification.test.js +59 -0
- package/dist/core/__tests__/final-verification.test.js.map +1 -0
- package/dist/core/__tests__/parallel-when-condition.test.d.ts +2 -0
- package/dist/core/__tests__/parallel-when-condition.test.d.ts.map +1 -0
- package/dist/core/__tests__/parallel-when-condition.test.js +155 -0
- package/dist/core/__tests__/parallel-when-condition.test.js.map +1 -0
- package/dist/core/__tests__/parser.test.d.ts +2 -0
- package/dist/core/__tests__/parser.test.d.ts.map +1 -0
- package/dist/core/__tests__/parser.test.js +94 -0
- package/dist/core/__tests__/parser.test.js.map +1 -0
- package/dist/core/__tests__/real-inquirer-test.test.d.ts +2 -0
- package/dist/core/__tests__/real-inquirer-test.test.d.ts.map +1 -0
- package/dist/core/__tests__/real-inquirer-test.test.js +20 -0
- package/dist/core/__tests__/real-inquirer-test.test.js.map +1 -0
- package/dist/core/__tests__/reproduce-bug.test.d.ts +2 -0
- package/dist/core/__tests__/reproduce-bug.test.d.ts.map +1 -0
- package/dist/core/__tests__/reproduce-bug.test.js +84 -0
- package/dist/core/__tests__/reproduce-bug.test.js.map +1 -0
- package/dist/core/__tests__/timeout-retry.test.d.ts +2 -0
- package/dist/core/__tests__/timeout-retry.test.d.ts.map +1 -0
- package/dist/core/__tests__/timeout-retry.test.js +184 -0
- package/dist/core/__tests__/timeout-retry.test.js.map +1 -0
- package/dist/core/__tests__/workflow-validation.test.d.ts +2 -0
- package/dist/core/__tests__/workflow-validation.test.d.ts.map +1 -0
- package/dist/core/__tests__/workflow-validation.test.js +120 -0
- package/dist/core/__tests__/workflow-validation.test.js.map +1 -0
- package/dist/core/__tests__/workspace.test.d.ts +2 -0
- package/dist/core/__tests__/workspace.test.d.ts.map +1 -0
- package/dist/core/__tests__/workspace.test.js +29 -0
- package/dist/core/__tests__/workspace.test.js.map +1 -0
- package/dist/core/__tests__/yaml-integration.test.d.ts +2 -0
- package/dist/core/__tests__/yaml-integration.test.d.ts.map +1 -0
- package/dist/core/__tests__/yaml-integration.test.js +114 -0
- package/dist/core/__tests__/yaml-integration.test.js.map +1 -0
- package/dist/core/__tests__/yaml-scenarios.test.d.ts +2 -0
- package/dist/core/__tests__/yaml-scenarios.test.d.ts.map +1 -0
- package/dist/core/__tests__/yaml-scenarios.test.js +199 -0
- package/dist/core/__tests__/yaml-scenarios.test.js.map +1 -0
- package/dist/core/condition-evaluator.d.ts +44 -0
- package/dist/core/condition-evaluator.d.ts.map +1 -0
- package/dist/core/condition-evaluator.js +121 -0
- package/dist/core/condition-evaluator.js.map +1 -0
- package/dist/core/executor.d.ts +172 -0
- package/dist/core/executor.d.ts.map +1 -0
- package/dist/core/executor.js +579 -0
- package/dist/core/executor.js.map +1 -0
- package/dist/core/parser.d.ts +41 -0
- package/dist/core/parser.d.ts.map +1 -0
- package/dist/core/parser.js +202 -0
- package/dist/core/parser.js.map +1 -0
- package/dist/core/rust-task-runner.d.ts +14 -0
- package/dist/core/rust-task-runner.d.ts.map +1 -0
- package/dist/core/rust-task-runner.js +34 -0
- package/dist/core/rust-task-runner.js.map +1 -0
- package/dist/core/task-runner.d.ts +63 -0
- package/dist/core/task-runner.d.ts.map +1 -0
- package/dist/core/task-runner.js +252 -0
- package/dist/core/task-runner.js.map +1 -0
- package/dist/core/template.d.ts +11 -0
- package/dist/core/template.d.ts.map +1 -0
- package/dist/core/template.js +36 -0
- package/dist/core/template.js.map +1 -0
- package/dist/core/workflow-schema.d.ts +31 -0
- package/dist/core/workflow-schema.d.ts.map +1 -0
- package/dist/core/workflow-schema.js +125 -0
- package/dist/core/workflow-schema.js.map +1 -0
- package/dist/core/workspace.d.ts +90 -0
- package/dist/core/workspace.d.ts.map +1 -0
- package/dist/core/workspace.js +143 -0
- package/dist/core/workspace.js.map +1 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +10 -0
- package/dist/index.js.map +1 -0
- package/dist/task-pipeliner-rs.node +0 -0
- package/dist/types/condition.d.ts +62 -0
- package/dist/types/condition.d.ts.map +1 -0
- package/dist/types/condition.js +6 -0
- package/dist/types/condition.js.map +1 -0
- package/dist/types/workflow.d.ts +69 -0
- package/dist/types/workflow.d.ts.map +1 -0
- package/dist/types/workflow.js +2 -0
- package/dist/types/workflow.js.map +1 -0
- package/package.json +67 -0
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* CLI Entry Point
|
|
4
|
+
*
|
|
5
|
+
* This is the main command-line interface for task-pipeliner.
|
|
6
|
+
*
|
|
7
|
+
* Usage:
|
|
8
|
+
* task-pipeliner run workflow.yaml
|
|
9
|
+
* task-pipeliner run workflow.json
|
|
10
|
+
*
|
|
11
|
+
* What it does:
|
|
12
|
+
* 1. Reads workflow file (YAML or JSON)
|
|
13
|
+
* 2. Parses workflow definition
|
|
14
|
+
* 3. Extracts step line numbers (for error reporting)
|
|
15
|
+
* 4. Executes workflow using Executor
|
|
16
|
+
* 5. Handles errors and displays results
|
|
17
|
+
*/
|
|
18
|
+
export {};
|
|
19
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":";AAEA;;;;;;;;;;;;;;;GAeG"}
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* CLI Entry Point
|
|
4
|
+
*
|
|
5
|
+
* This is the main command-line interface for task-pipeliner.
|
|
6
|
+
*
|
|
7
|
+
* Usage:
|
|
8
|
+
* task-pipeliner run workflow.yaml
|
|
9
|
+
* task-pipeliner run workflow.json
|
|
10
|
+
*
|
|
11
|
+
* What it does:
|
|
12
|
+
* 1. Reads workflow file (YAML or JSON)
|
|
13
|
+
* 2. Parses workflow definition
|
|
14
|
+
* 3. Extracts step line numbers (for error reporting)
|
|
15
|
+
* 4. Executes workflow using Executor
|
|
16
|
+
* 5. Handles errors and displays results
|
|
17
|
+
*/
|
|
18
|
+
import { exec } from 'child_process';
|
|
19
|
+
import { readFileSync } from 'fs';
|
|
20
|
+
import { resolve } from 'path';
|
|
21
|
+
import { promisify } from 'util';
|
|
22
|
+
import chalk from 'chalk';
|
|
23
|
+
import { Command } from 'commander';
|
|
24
|
+
import { Executor } from '../core/executor.js';
|
|
25
|
+
import { getParser } from '../core/parser.js';
|
|
26
|
+
const execAsync = promisify(exec);
|
|
27
|
+
const program = new Command();
|
|
28
|
+
program
|
|
29
|
+
.name('task-pipeliner')
|
|
30
|
+
.description('A powerful task pipeline runner with condition-based workflow execution.\n\n' +
|
|
31
|
+
'Define workflows in YAML or JSON files with conditional execution, parallel tasks,\n' +
|
|
32
|
+
'interactive prompts, and variable substitution.\n\n' +
|
|
33
|
+
'Features:\n' +
|
|
34
|
+
' • Condition-based execution (file checks, variable comparisons)\n' +
|
|
35
|
+
' • Parallel task execution\n' +
|
|
36
|
+
' • Interactive prompts and choices\n' +
|
|
37
|
+
' • Variable substitution with {{variables}}\n' +
|
|
38
|
+
' • Beautiful terminal output\n' +
|
|
39
|
+
' • Supports both YAML (.yaml, .yml) and JSON (.json) formats\n\n' +
|
|
40
|
+
'Quick Start:\n' +
|
|
41
|
+
' 1. Create a workflow.yaml or workflow.json file:\n' +
|
|
42
|
+
' steps:\n' +
|
|
43
|
+
' - run: echo "Hello, World!"\n' +
|
|
44
|
+
' - choose:\n' +
|
|
45
|
+
' message: "Select action:"\n' +
|
|
46
|
+
' options:\n' +
|
|
47
|
+
' - id: build\n' +
|
|
48
|
+
' label: "Build"\n' +
|
|
49
|
+
' as: action\n' +
|
|
50
|
+
' - when:\n' +
|
|
51
|
+
' var:\n' +
|
|
52
|
+
' action: build\n' +
|
|
53
|
+
' run: npm run build\n\n' +
|
|
54
|
+
' 2. Run it:\n' +
|
|
55
|
+
' tp run workflow.yaml\n' +
|
|
56
|
+
' tp run workflow.json\n\n' +
|
|
57
|
+
'Resources:\n' +
|
|
58
|
+
' 📚 Documentation: https://task-pipeliner.racgoo.com/\n' +
|
|
59
|
+
' 🎨 Visual Generator: https://task-pipeliner-generator.racgoo.com/\n' +
|
|
60
|
+
' 💻 Quick access: tp open docs | tp open generator')
|
|
61
|
+
.version('0.1.0')
|
|
62
|
+
.addHelpText('after', '\nExamples:\n $ tp run workflow.yaml\n $ tp run examples/simple-project/workflow.yaml\n $ tp open docs # Open documentation\n $ tp open generator # Open visual generator\n\nResources:\n 📚 Documentation: https://task-pipeliner.racgoo.com/\n 🎨 Visual Generator: https://task-pipeliner-generator.racgoo.com/\n\nSee README.md for complete DSL reference.');
|
|
63
|
+
program
|
|
64
|
+
.command('run')
|
|
65
|
+
.description('Run a workflow from a YAML or JSON file')
|
|
66
|
+
.argument('<file>', 'Path to the workflow file (YAML or JSON, relative or absolute)')
|
|
67
|
+
.addHelpText('after', '\nExamples:\n $ tp run workflow.yaml\n $ tp run workflow.json\n $ tp run ./my-workflow.yaml\n $ tp run examples/simple-project/workflow.json\n\nWorkflow File Structure:\n A workflow file must contain a "steps" array with step definitions.\n Each step can be:\n • run: Execute a shell command\n • choose: Prompt user to select from options\n • prompt: Ask user for text input\n • parallel: Run multiple steps simultaneously\n • fail: Stop workflow with error message\n\n Steps can have "when" conditions to control execution:\n • file: Check if file/directory exists\n • var: Check variable value or existence\n • all/any/not: Combine conditions\n\n Supported formats: YAML (.yaml, .yml) and JSON (.json)\n See README.md for complete DSL documentation.')
|
|
68
|
+
.action(async (file) => {
|
|
69
|
+
try {
|
|
70
|
+
// Step 1: Get appropriate parser based on file extension
|
|
71
|
+
const parser = getParser(file);
|
|
72
|
+
// Step 2: Load and parse workflow file
|
|
73
|
+
console.log(chalk.blue(`Loading workflow from ${file}...`));
|
|
74
|
+
const content = readFileSync(file, 'utf-8');
|
|
75
|
+
const workflow = parser.parse(content);
|
|
76
|
+
// Step 3: Validate workflow structure
|
|
77
|
+
if (!workflow.steps || !Array.isArray(workflow.steps)) {
|
|
78
|
+
throw new Error('Invalid workflow: steps array is required');
|
|
79
|
+
}
|
|
80
|
+
// Step 4: Extract metadata for error reporting
|
|
81
|
+
workflow._lineNumbers = parser.extractStepLineNumbers(content); // Map step index -> line number
|
|
82
|
+
workflow._fileName = extractFileName(file); // Just the filename, not full path
|
|
83
|
+
// Step 5: Store absolute file path (needed for resolving relative baseDir)
|
|
84
|
+
workflow._filePath = resolve(file);
|
|
85
|
+
// Step 6: Execute workflow
|
|
86
|
+
console.log(chalk.green('Starting workflow execution...\n'));
|
|
87
|
+
const executor = new Executor();
|
|
88
|
+
await executor.execute(workflow);
|
|
89
|
+
// Step 7: Success message
|
|
90
|
+
console.log(chalk.green('\n✓ Workflow completed successfully'));
|
|
91
|
+
}
|
|
92
|
+
catch (error) {
|
|
93
|
+
// Handle errors: show simple message, no stack trace
|
|
94
|
+
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
95
|
+
console.error(chalk.red(`\n✗ Workflow failed: ${errorMessage}`));
|
|
96
|
+
process.exit(1);
|
|
97
|
+
}
|
|
98
|
+
});
|
|
99
|
+
program
|
|
100
|
+
.command('open')
|
|
101
|
+
.description('Open generator or docs website in browser')
|
|
102
|
+
.argument('<target>', 'Target to open: "generator" or "docs"')
|
|
103
|
+
.addHelpText('after', '\nExamples:\n $ tp open generator\n $ tp open docs\n\nTargets:\n generator Open the visual workflow generator (https://task-pipeliner-generator.racgoo.com/)\n docs Open the documentation site (https://task-pipeliner.racgoo.com/)')
|
|
104
|
+
.action(async (target) => {
|
|
105
|
+
const urls = {
|
|
106
|
+
generator: 'https://task-pipeliner-generator.racgoo.com/',
|
|
107
|
+
docs: 'https://task-pipeliner.racgoo.com/',
|
|
108
|
+
};
|
|
109
|
+
const url = urls[target.toLowerCase()];
|
|
110
|
+
if (!url) {
|
|
111
|
+
console.error(chalk.red(`\n✗ Invalid target: ${target}`));
|
|
112
|
+
console.log(chalk.yellow('\nValid targets:'));
|
|
113
|
+
console.log(chalk.yellow(' • generator - Open the visual workflow generator'));
|
|
114
|
+
console.log(chalk.yellow(' • docs - Open the documentation site'));
|
|
115
|
+
process.exit(1);
|
|
116
|
+
}
|
|
117
|
+
try {
|
|
118
|
+
const platform = process.platform;
|
|
119
|
+
let command;
|
|
120
|
+
if (platform === 'darwin') {
|
|
121
|
+
command = `open "${url}"`;
|
|
122
|
+
}
|
|
123
|
+
else if (platform === 'win32') {
|
|
124
|
+
command = `start "${url}"`;
|
|
125
|
+
}
|
|
126
|
+
else {
|
|
127
|
+
command = `xdg-open "${url}"`;
|
|
128
|
+
}
|
|
129
|
+
await execAsync(command);
|
|
130
|
+
console.log(chalk.green(`\n✓ Opening ${target === 'generator' ? 'generator' : 'documentation'} in browser...`));
|
|
131
|
+
console.log(chalk.blue(` ${url}`));
|
|
132
|
+
}
|
|
133
|
+
catch (error) {
|
|
134
|
+
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
135
|
+
console.error(chalk.red(`\n✗ Failed to open browser: ${errorMessage}`));
|
|
136
|
+
console.log(chalk.yellow(`\nPlease visit manually: ${url}`));
|
|
137
|
+
process.exit(1);
|
|
138
|
+
}
|
|
139
|
+
});
|
|
140
|
+
/**
|
|
141
|
+
* Extract filename from file path
|
|
142
|
+
*/
|
|
143
|
+
function extractFileName(filePath) {
|
|
144
|
+
return filePath.split('/').pop() || filePath;
|
|
145
|
+
}
|
|
146
|
+
program.parse();
|
|
147
|
+
//# sourceMappingUR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CAAC"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Choice Prompt
|
|
3
|
+
*
|
|
4
|
+
* Shows user a selection menu with multiple options.
|
|
5
|
+
* User can select one option using arrow keys and Enter.
|
|
6
|
+
*
|
|
7
|
+
* Example:
|
|
8
|
+
* Choose environment:
|
|
9
|
+
* > Development
|
|
10
|
+
* Staging
|
|
11
|
+
* Production
|
|
12
|
+
*/
|
|
13
|
+
export declare class ChoicePrompt {
|
|
14
|
+
/**
|
|
15
|
+
* Show choice menu to user and return selected option
|
|
16
|
+
*
|
|
17
|
+
* @param message - Question to ask user
|
|
18
|
+
* @param options - List of options (each has id and label)
|
|
19
|
+
* @returns Selected option object
|
|
20
|
+
*/
|
|
21
|
+
prompt(message: string, options: Array<{
|
|
22
|
+
id: string;
|
|
23
|
+
label: string;
|
|
24
|
+
}>): Promise<{
|
|
25
|
+
id: string;
|
|
26
|
+
label: string;
|
|
27
|
+
}>;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Text Prompt
|
|
31
|
+
*
|
|
32
|
+
* Asks user to type text input.
|
|
33
|
+
* User can type anything and press Enter.
|
|
34
|
+
*
|
|
35
|
+
* Example:
|
|
36
|
+
* Enter version number: 1.0.0
|
|
37
|
+
*/
|
|
38
|
+
export declare class TextPrompt {
|
|
39
|
+
/**
|
|
40
|
+
* Ask user for text input
|
|
41
|
+
*
|
|
42
|
+
* @param message - Question to ask user
|
|
43
|
+
* @param defaultValue - Optional default value (shown in brackets)
|
|
44
|
+
* @returns User's input text
|
|
45
|
+
*/
|
|
46
|
+
prompt(message: string, defaultValue?: string): Promise<string>;
|
|
47
|
+
}
|
|
48
|
+
//# sourceMappingURL=prompts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prompts.d.ts","sourceRoot":"","sources":["../../src/cli/prompts.ts"],"names":[],"mappings":"AAGA;;;;;;;;;;;GAWG;AACH,qBAAa,YAAY;IACvB;;;;;;OAMG;IACG,MAAM,CACV,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,KAAK,CAAC;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,GAC5C,OAAO,CAAC;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC;CAsB1C;AAED;;;;;;;;GAQG;AACH,qBAAa,UAAU;IACrB;;;;;;OAMG;IACG,MAAM,CACV,OAAO,EAAE,MAAM,EACf,YAAY,CAAC,EAAE,MAAM,GACpB,OAAO,CAAC,MAAM,CAAC;CAanB"}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import chalk from 'chalk';
|
|
2
|
+
import inquirer from 'inquirer';
|
|
3
|
+
/**
|
|
4
|
+
* Choice Prompt
|
|
5
|
+
*
|
|
6
|
+
* Shows user a selection menu with multiple options.
|
|
7
|
+
* User can select one option using arrow keys and Enter.
|
|
8
|
+
*
|
|
9
|
+
* Example:
|
|
10
|
+
* Choose environment:
|
|
11
|
+
* > Development
|
|
12
|
+
* Staging
|
|
13
|
+
* Production
|
|
14
|
+
*/
|
|
15
|
+
export class ChoicePrompt {
|
|
16
|
+
/**
|
|
17
|
+
* Show choice menu to user and return selected option
|
|
18
|
+
*
|
|
19
|
+
* @param message - Question to ask user
|
|
20
|
+
* @param options - List of options (each has id and label)
|
|
21
|
+
* @returns Selected option object
|
|
22
|
+
*/
|
|
23
|
+
async prompt(message, options) {
|
|
24
|
+
// Use inquirer to show interactive menu
|
|
25
|
+
const { choice } = await inquirer.prompt([
|
|
26
|
+
{
|
|
27
|
+
type: 'list',
|
|
28
|
+
name: 'choice',
|
|
29
|
+
message: chalk.cyan(message),
|
|
30
|
+
// Convert our options format to inquirer format
|
|
31
|
+
choices: options.map((opt) => ({
|
|
32
|
+
name: opt.label, // What user sees
|
|
33
|
+
value: opt.id, // What we get back
|
|
34
|
+
})),
|
|
35
|
+
},
|
|
36
|
+
]);
|
|
37
|
+
// Find the full option object by id
|
|
38
|
+
const selected = options.find((opt) => opt.id === choice);
|
|
39
|
+
if (!selected) {
|
|
40
|
+
throw new Error(`Invalid choice: ${choice}`);
|
|
41
|
+
}
|
|
42
|
+
return selected;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Text Prompt
|
|
47
|
+
*
|
|
48
|
+
* Asks user to type text input.
|
|
49
|
+
* User can type anything and press Enter.
|
|
50
|
+
*
|
|
51
|
+
* Example:
|
|
52
|
+
* Enter version number: 1.0.0
|
|
53
|
+
*/
|
|
54
|
+
export class TextPrompt {
|
|
55
|
+
/**
|
|
56
|
+
* Ask user for text input
|
|
57
|
+
*
|
|
58
|
+
* @param message - Question to ask user
|
|
59
|
+
* @param defaultValue - Optional default value (shown in brackets)
|
|
60
|
+
* @returns User's input text
|
|
61
|
+
*/
|
|
62
|
+
async prompt(message, defaultValue) {
|
|
63
|
+
// Use inquirer to show text input field
|
|
64
|
+
const { value } = await inquirer.prompt([
|
|
65
|
+
{
|
|
66
|
+
type: 'input',
|
|
67
|
+
name: 'value',
|
|
68
|
+
message: chalk.cyan(message),
|
|
69
|
+
default: defaultValue, // Shown as [defaultValue] if provided
|
|
70
|
+
},
|
|
71
|
+
]);
|
|
72
|
+
return value;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
//# sourceMappingURL=prompts.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prompts.js","sourceRoot":"","sources":["../../src/cli/prompts.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,QAAQ,MAAM,UAAU,CAAC;AAEhC;;;;;;;;;;;GAWG;AACH,MAAM,OAAO,YAAY;IACvB;;;;;;OAMG;IACH,KAAK,CAAC,MAAM,CACV,OAAe,EACf,OAA6C;QAE7C,wCAAwC;QACxC,MAAM,EAAE,MAAM,EAAE,GAAG,MAAM,QAA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oxOptions {
|
|
6
|
+
title?: string;
|
|
7
|
+
borderColor?: 'cyan' | 'green' | 'yellow' | 'red' | 'blue';
|
|
8
|
+
isNested?: boolean;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Create step header box
|
|
12
|
+
*/
|
|
13
|
+
export declare function createStepHeaderBox(content: string, lineNumber?: number, fileName?: string, options?: BoxOptions): string;
|
|
14
|
+
/**
|
|
15
|
+
* Create step completion message (no box, just colored text)
|
|
16
|
+
*/
|
|
17
|
+
export declare function createStepFooterMessage(success: boolean, _isNested?: boolean): string;
|
|
18
|
+
/**
|
|
19
|
+
* Create error box
|
|
20
|
+
*/
|
|
21
|
+
export declare function createErrorBox(error: string): string;
|
|
22
|
+
/**
|
|
23
|
+
* Create parallel execution header box
|
|
24
|
+
*/
|
|
25
|
+
export declare function createParallelHeaderBox(branchCount: number): string;
|
|
26
|
+
/**
|
|
27
|
+
* Create parallel execution footer message (no box, just colored text)
|
|
28
|
+
*/
|
|
29
|
+
export declare function createParallelFooterMessage(allSucceeded: boolean): string;
|
|
30
|
+
/**
|
|
31
|
+
* Step divider line (deprecated - no longer used)
|
|
32
|
+
* @deprecated Dividers are no longer displayed
|
|
33
|
+
*/
|
|
34
|
+
export declare function createDivider(): string;
|
|
35
|
+
/**
|
|
36
|
+
* Format nested output line
|
|
37
|
+
*/
|
|
38
|
+
export declare function formatNestedLine(line: string, isNested?: boolean): string;
|
|
39
|
+
//# sourceMappingURL=ui.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ui.d.ts","sourceRoot":"","sources":["../../src/cli/ui.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAKH,MAAM,WAAW,UAAU;IACzB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,GAAG,OAAO,GAAG,QAAQ,GAAG,KAAK,GAAG,MAAM,CAAC;IAC3D,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CACjC,OAAO,EAAE,MAAM,EACf,UAAU,CAAC,EAAE,MAAM,EACnB,QAAQ,CAAC,EAAE,MAAM,EACjB,OAAO,GAAE,UAAe,GACvB,MAAM,CA0BR;AAED;;GAEG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,OAAO,EAChB,SAAS,GAAE,OAAe,GACzB,MAAM,CAGR;AAED;;GAEG;AACH,wBAAgB,cAAc,CAC5B,KAAK,EAAE,MAAM,GACZ,MAAM,CAUR;AAED;;GAEG;AACH,wBAAgB,uBAAuB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAUnE;AAED;;GAEG;AACH,wBAAgB,2BAA2B,CAAC,YAAY,EAAE,OAAO,GAAG,MAAM,CAKzE;AAED;;;GAGG;AACH,wBAAgB,aAAa,IAAI,MAAM,CAEtC;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,GAAE,OAAe,GAAG,MAAM,CAGhF"}
|
package/dist/cli/ui.js
ADDED
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* UI Utilities
|
|
3
|
+
* Common UI components for CLI output (boxes, dividers, etc.)
|
|
4
|
+
*/
|
|
5
|
+
import boxen from 'boxen';
|
|
6
|
+
import chalk from 'chalk';
|
|
7
|
+
/**
|
|
8
|
+
* Create step header box
|
|
9
|
+
*/
|
|
10
|
+
export function createStepHeaderBox(content, lineNumber, fileName, options = {}) {
|
|
11
|
+
const { borderColor = 'cyan', isNested = false } = options;
|
|
12
|
+
// Create title with line number and file name
|
|
13
|
+
let title;
|
|
14
|
+
if (lineNumber !== undefined) {
|
|
15
|
+
if (fileName) {
|
|
16
|
+
title = `line ${lineNumber} in ${fileName}`;
|
|
17
|
+
}
|
|
18
|
+
else {
|
|
19
|
+
title = `line ${lineNumber}`;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
// Add indentation when nested
|
|
23
|
+
const displayContent = isNested ? `│ ${content}` : `> ${content}`;
|
|
24
|
+
return boxen(displayContent, {
|
|
25
|
+
title: title,
|
|
26
|
+
borderStyle: 'round',
|
|
27
|
+
padding: { top: 0, bottom: 0, left: 1, right: 1 },
|
|
28
|
+
margin: { top: 0, bottom: 0 },
|
|
29
|
+
borderColor: borderColor,
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Create step completion message (no box, just colored text)
|
|
34
|
+
*/
|
|
35
|
+
export function createStepFooterMessage(success, _isNested = false) {
|
|
36
|
+
const statusText = success ? '✓ Completed' : '✗ Failed';
|
|
37
|
+
return success ? chalk.green(statusText) : chalk.red(statusText);
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Create error box
|
|
41
|
+
*/
|
|
42
|
+
export function createErrorBox(error) {
|
|
43
|
+
return boxen(`✗ ${error}`, {
|
|
44
|
+
borderStyle: 'round',
|
|
45
|
+
padding: { top: 0, bottom: 0, left: 1, right: 1 },
|
|
46
|
+
margin: { top: 0, bottom: 0 },
|
|
47
|
+
borderColor: 'red',
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Create parallel execution header box
|
|
52
|
+
*/
|
|
53
|
+
export function createParallelHeaderBox(branchCount) {
|
|
54
|
+
return boxen(`> Starting parallel execution (${branchCount} branches)`, {
|
|
55
|
+
borderStyle: 'round',
|
|
56
|
+
padding: { top: 0, bottom: 0, left: 1, right: 1 },
|
|
57
|
+
margin: { top: 0, bottom: 0 },
|
|
58
|
+
borderColor: 'yellow',
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Create parallel execution footer message (no box, just colored text)
|
|
63
|
+
*/
|
|
64
|
+
export function createParallelFooterMessage(allSucceeded) {
|
|
65
|
+
const statusText = allSucceeded
|
|
66
|
+
? '✓ All parallel branches completed'
|
|
67
|
+
: '✗ Some parallel branches failed';
|
|
68
|
+
return allSucceeded ? chalk.green(statusText) : chalk.red(statusText);
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Step divider line (deprecated - no longer used)
|
|
72
|
+
* @deprecated Dividers are no longer displayed
|
|
73
|
+
*/
|
|
74
|
+
export function createDivider() {
|
|
75
|
+
return '';
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* Format nested output line
|
|
79
|
+
*/
|
|
80
|
+
export function formatNestedLine(line, isNested = false) {
|
|
81
|
+
const prefix = isNested ? '| │ ' : '│ ';
|
|
82
|
+
return `${prefix}${line}`;
|
|
83
|
+
}
|
|
84
|
+
//# sourceMappingURL=ui.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ui.js","sourceRoot":"","sources":["../../src/cli/ui.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B;;GAEG;AACH,MAAM,UAAU,mBAAmB,CACjC,OAAe,EACf,UAAmB,EACnB,QAAiB,EACjB,UAAsB,EAAE;IAExB,MAAM,EAAE,WAAW,GAAG,MAAM,EAAE,QAAQ,GAAG,KAAK,EAAE,GAAG,OAAO,CAAC;IAE3D,8CAA8C;IAC9C,IAAI,KAAyB,CAAC;IAC9B,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;QAC7B,IAAI,QAAQ,EAAE,CAAC;YACb,KAAK,GAAG,QAAQ,UAAU,OAAO,QAAQ,EAAE,CAAC;QAC9C,CAAC;aAAM,CAAC;YACN,KAAK,GAAG,QAAQ,UAAU,EAAE,CAAC;QAC/B,CAAC;IACH,CAAC;IAED,8BAA8B;IAC9B,MAAM,cAAc,GAAG,QAAQ,CAAC,CAAC,CAAC,KAAK,OAAO,EAAE,CAAC,CAAC,CAAC,KAAK,OAAO,EAAE,CAAC;IAElE,OAAO,KAAK,CACV,cAAc,EACd;QACE,KAAK,EAAE,KAAK;QACZ,WAAW,EAAE,OA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C7B,WAAW,EAAE,QAAQ;KACtB,CACF,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,2BAA2B,CAAC,YAAqB;IAC/D,MAAM,UAAU,GAAG,YAAY;QAC7B,CAAC,CAAC,mCAAmC;QACrC,CAAC,CAAC,iCAAiC,CAAC;IACtC,OAAO,YAAY,CAAC,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;AACxE,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,aAAa;IAC3B,OAAO,EAAE,CAAC;AACZ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,gBAAgB,CAAC,IAAY,EAAE,WAAoB,KAAK;IACtE,MAAM,MAAM,GAAG,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC;IACxC,OAAO,GAAG,MAAM,GAAG,IAAI,EAAE,CAAC;AAC5B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"actual-execution.test.d.ts","sourceRoot":"","sources":["../../../src/core/__tests__/actual-execution.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
import { readFileSync } from 'fs';
|
|
2
|
+
import { describe, it, expect, vi } from 'vitest';
|
|
3
|
+
import { parse } from 'yaml';
|
|
4
|
+
import { ConditionEvaluator } from '../condition-evaluator.js';
|
|
5
|
+
import { Executor } from '../executor.js';
|
|
6
|
+
// Simulate actual execution
|
|
7
|
+
describe('ACTUAL EXECUTION SIMULATION - Must Fix', () => {
|
|
8
|
+
it('should execute basic.yaml EXACTLY as real execution', async () => {
|
|
9
|
+
// 1. Load YAML file (same as actual)
|
|
10
|
+
const content = readFileSync('examples/yaml-examples/basic.yaml', 'utf-8');
|
|
11
|
+
const workflow = parse(content);
|
|
12
|
+
// 2. Create Executor
|
|
13
|
+
const executor = new Executor();
|
|
14
|
+
const workspace = executor.workspace;
|
|
15
|
+
const choicePrompt = executor.choicePrompt;
|
|
16
|
+
const taskRunner = executor.taskRunner;
|
|
17
|
+
// 3. Simulate actual execution
|
|
18
|
+
const executedCommands = [];
|
|
19
|
+
const mockRun = vi.fn().mockImplementation((cmd) => {
|
|
20
|
+
executedCommands.push(cmd);
|
|
21
|
+
console.log(`[RUN] ${cmd}`);
|
|
22
|
+
return Promise.resolve(true);
|
|
23
|
+
});
|
|
24
|
+
taskRunner.run = mockRun;
|
|
25
|
+
// 4. Mock choice prompt (like actual inquirer)
|
|
26
|
+
const mockPrompt = vi.fn().mockResolvedValue({ id: 'staging', label: 'Staging' });
|
|
27
|
+
choicePrompt.prompt = mockPrompt;
|
|
28
|
+
// Mock TextPrompt (prevent timeout)
|
|
29
|
+
const textPrompt = executor.textPrompt;
|
|
30
|
+
textPrompt.prompt = vi.fn().mockResolvedValue('1.0.0');
|
|
31
|
+
// 5. CI environment variable
|
|
32
|
+
process.env.CI = 'false';
|
|
33
|
+
try {
|
|
34
|
+
// 6. Execute
|
|
35
|
+
await executor.execute(workflow);
|
|
36
|
+
// 7. Verify
|
|
37
|
+
console.log('\n=== EXECUTION RESULT ===');
|
|
38
|
+
console.log('Executed commands:', executedCommands);
|
|
39
|
+
console.log('Workspace choices:', Array.from(workspace.state.choices.entries()));
|
|
40
|
+
console.log('Workspace facts:', Array.from(workspace.state.facts.entries()));
|
|
41
|
+
// Required verification
|
|
42
|
+
expect(executedCommands).toContain('echo "Deploying to staging..."');
|
|
43
|
+
expect(executedCommands).not.toContain('echo "Deploying to production..."');
|
|
44
|
+
expect(workspace.hasChoice('staging')).toBe(true);
|
|
45
|
+
// Verify each step
|
|
46
|
+
expect(executedCommands[0]).toBe('echo "Building..."');
|
|
47
|
+
expect(executedCommands).toContain('echo "Deploying to staging..."');
|
|
48
|
+
console.log('\n✅ ALL CHECKS PASSED');
|
|
49
|
+
}
|
|
50
|
+
finally {
|
|
51
|
+
delete process.env.CI;
|
|
52
|
+
}
|
|
53
|
+
});
|
|
54
|
+
it('should verify choice is set BEFORE next step evaluation', async () => {
|
|
55
|
+
const workflow = {
|
|
56
|
+
steps: [
|
|
57
|
+
{
|
|
58
|
+
choose: {
|
|
59
|
+
message: 'Choose?',
|
|
60
|
+
options: [{ id: 'staging', label: 'Staging' }],
|
|
61
|
+
},
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
choose: {
|
|
65
|
+
message: 'Choose?',
|
|
66
|
+
options: [{ id: 'staging', label: 'Staging' }],
|
|
67
|
+
as: 'env',
|
|
68
|
+
},
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
when: {
|
|
72
|
+
var: {
|
|
73
|
+
env: 'staging'
|
|
74
|
+
}
|
|
75
|
+
},
|
|
76
|
+
run: 'echo "After choice"',
|
|
77
|
+
},
|
|
78
|
+
],
|
|
79
|
+
};
|
|
80
|
+
const executor = new Executor();
|
|
81
|
+
const workspace = executor.workspace;
|
|
82
|
+
const choicePrompt = executor.choicePrompt;
|
|
83
|
+
const taskRunner = executor.taskRunner;
|
|
84
|
+
const executedCommands = [];
|
|
85
|
+
taskRunner.run = vi.fn().mockImplementation((cmd) => {
|
|
86
|
+
executedCommands.push(cmd);
|
|
87
|
+
return Promise.resolve(true);
|
|
88
|
+
});
|
|
89
|
+
choicePrompt.prompt = vi.fn()
|
|
90
|
+
.mockResolvedValueOnce({ id: 'staging', label: 'Staging' })
|
|
91
|
+
.mockResolvedValueOnce({ id: 'staging', label: 'Staging' });
|
|
92
|
+
await executor.execute(workflow);
|
|
93
|
+
// Check if choice is set
|
|
94
|
+
expect(workspace.hasChoice('staging')).toBe(true);
|
|
95
|
+
expect(executedCommands).toContain('echo "After choice"');
|
|
96
|
+
});
|
|
97
|
+
it('should manually trace step execution', async () => {
|
|
98
|
+
const workflow = {
|
|
99
|
+
steps: [
|
|
100
|
+
{ run: 'step1' },
|
|
101
|
+
{ choose: { message: 'Choose?', options: [{ id: 'opt1', label: 'Option 1' }], as: 'choice' } },
|
|
102
|
+
{ when: { var: { choice: 'opt1' } }, run: 'step3' },
|
|
103
|
+
],
|
|
104
|
+
};
|
|
105
|
+
const executor = new Executor();
|
|
106
|
+
const workspace = executor.workspace;
|
|
107
|
+
const choicePrompt = executor.choicePrompt;
|
|
108
|
+
const taskRunner = executor.taskRunner;
|
|
109
|
+
const executedCommands = [];
|
|
110
|
+
taskRunner.run = vi.fn().mockImplementation((cmd) => {
|
|
111
|
+
executedCommands.push(cmd);
|
|
112
|
+
console.log(`Executing: ${cmd}`);
|
|
113
|
+
return Promise.resolve(true);
|
|
114
|
+
});
|
|
115
|
+
choicePrompt.prompt = vi.fn().mockResolvedValue({ id: 'opt1', label: 'Option 1' });
|
|
116
|
+
// Step-by-step trace
|
|
117
|
+
console.log('\n=== STEP BY STEP TRACE ===');
|
|
118
|
+
// Step 0: run
|
|
119
|
+
await executor.executeStep(workflow.steps[0], { workspace, stepIndex: 0 });
|
|
120
|
+
console.log('After step 0:', workspace.hasFact('fact1'));
|
|
121
|
+
// Step 1: choose
|
|
122
|
+
await executor.executeChooseStep(workflow.steps[1], { workspace, stepIndex: 1 });
|
|
123
|
+
console.log('After step 1 (choose):', workspace.hasChoice('opt1'));
|
|
124
|
+
// Step 2: when + run
|
|
125
|
+
const step2 = workflow.steps[2];
|
|
126
|
+
if (step2 && 'when' in step2 && step2.when) {
|
|
127
|
+
const evaluator = new ConditionEvaluator(workspace);
|
|
128
|
+
const conditionResult = evaluator.evaluate(step2.when);
|
|
129
|
+
console.log('Step 2 condition result:', conditionResult);
|
|
130
|
+
if (conditionResult) {
|
|
131
|
+
await executor.executeRunStep(step2, { workspace, stepIndex: 2 });
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
else if (step2) {
|
|
135
|
+
await executor.executeRunStep(step2, { workspace, stepIndex: 2 });
|
|
136
|
+
}
|
|
137
|
+
expect(executedCommands).toContain('step3');
|
|
138
|
+
});
|
|
139
|
+
});
|
|
140
|
+
//# sourceMappingURL=actual-execution.test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"actual-execution.test.js","sourceRoot":"","sources":["../../../src/core/__tests__/actual-execution.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,IAAI,CAAC;AAClC,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,QAAQ,CAAC;AAClD,OAAO,EAAE,KAAK,EAAE,MAAM,MAAM,CAAC;AAC7B,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAE1C,4BAA4B;AAC5B,QAAQ,CAAC,wCAAwC,EAAE,GAAG,EAAE;IACtD,EAAE,CAAC,qDAAqD,EAAE,KAAK,IAAI,EAAE;QACnE,qCAAqC;QACrC,MAAM,OAAO,GAAG,YAAY,CAAC,mCAAmC,EAAE,OAAO,CAAC,CAAC;QAC3E,MAAM,QAAQ,GAAG,KAAK,CAAC,OAAO,CAAC,CAAC;QAEhC,qBAAqB;QACrB,MAAM,QAAQ,GAAG,IAAI,QAAQ,EAAE,CAAC;QAChC,MAAM,SAAS,GAAI,QAAgB,CAAC,SAAS,CAAC;QAC9C,MAAM,YAAY,GAAI,QAAgB,CAAC,YAAY,CAAC;QACpD,MAAM,UAAU,GAAI,QAAgB,CAAC,UAAU,CAAC;QAEhD,+BAA+B;QAC/B,MAAM,gBAAgB,GAAa,EAAE,CAAC;QACtC,MAAM,OAAO,GAAG,EAAE,CAAC,EAAE,EAAE,CAAC,kBAAkB,CAAC,CAAC,GAAW,EAAE,EAAE;YACzD,gBAAgB,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YAC3B,OAAO,CAAC,GAAG,CAAC,SAAS,GAAG,EAAE,CAAC,CAAC;YAC5B,OAAO,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;QAC/B,CAAC,CAAC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