Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/commands/workflow.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ import {
headlessGateErrors,
RunStatus,
LeaseHeldError,
} from "../factory/engine.mjs";
import { STEP_REGISTRY } from "../factory/registry.mjs";
} from "../workflow/engine.mjs";
import { STEP_REGISTRY } from "../workflow/registry.mjs";
import {
stateStart,
stateAdvance,
statePause,
stateFail,
stateShow,
} from "../factory/state.mjs";
} from "../workflow/state.mjs";
import { printWorkflowHelp } from "../help.mjs";
import { classifyWorkflowStatus } from "../exit-codes.mjs";

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions tests/workflow-engine.test.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ import assert from "node:assert/strict";
import { mkdtempSync, rmSync, existsSync, readFileSync, writeFileSync, mkdirSync } from "node:fs";
import { tmpdir } from "node:os";
import { join } from "node:path";
import { WorkflowEngine, WorkflowDefinition, validateWorkflow, RunStatus } from "../src/factory/engine.mjs";
import { STEP_REGISTRY } from "../src/factory/registry.mjs";
import { StepStatus } from "../src/factory/base.mjs";
import { WorkflowEngine, WorkflowDefinition, validateWorkflow, RunStatus } from "../src/workflow/engine.mjs";
import { STEP_REGISTRY } from "../src/workflow/registry.mjs";
import { StepStatus } from "../src/workflow/base.mjs";

function makeProject() {
const dir = mkdtempSync(join(tmpdir(), "factory-test-"));
Expand Down
6 changes: 3 additions & 3 deletions tests/workflow-events.test.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ import {
validateWorkflow,
headlessGateErrors,
RunStatus,
} from "../src/factory/engine.mjs";
import { STEP_REGISTRY } from "../src/factory/registry.mjs";
import { BUILTIN_WORKFLOWS } from "../src/factory/builtins.mjs";
} from "../src/workflow/engine.mjs";
import { STEP_REGISTRY } from "../src/workflow/registry.mjs";
import { BUILTIN_WORKFLOWS } from "../src/workflow/builtins.mjs";

function makeProject({ git = false } = {}) {
const dir = mkdtempSync(join(tmpdir(), "wf-events-"));
Expand Down
2 changes: 1 addition & 1 deletion tests/workflow-expressions.test.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
conditionIsNeverEvaluated,
conditionHasMalformedExpressionBlock,
conditionIsInterpolatedToText,
} from "../src/factory/expressions.mjs";
} from "../src/workflow/expressions.mjs";

const ctx = (fields = {}) => ({
inputs: { name: "auth", count: 3, ready: false, text: "hello world", tags: ["a", "b"] },
Expand Down
14 changes: 7 additions & 7 deletions tests/workflow-parity.test.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ import assert from "node:assert/strict";
import { mkdtempSync, rmSync, writeFileSync, readFileSync, existsSync } from "node:fs";
import { tmpdir } from "node:os";
import { join } from "node:path";
import { evaluateExpression, evaluateCondition } from "../src/factory/expressions.mjs";
import { StepContext, StepStatus, RunStatus } from "../src/factory/base.mjs";
import { WorkflowEngine, WorkflowDefinition, RunState, validateWorkflow } from "../src/factory/engine.mjs";
import { STEP_REGISTRY, getStepType } from "../src/factory/registry.mjs";
import { GateStep } from "../src/factory/steps/gate.mjs";
import { evaluateExpression, evaluateCondition } from "../src/workflow/expressions.mjs";
import { StepContext, StepStatus, RunStatus } from "../src/workflow/base.mjs";
import { WorkflowEngine, WorkflowDefinition, RunState, validateWorkflow } from "../src/workflow/engine.mjs";
import { STEP_REGISTRY, getStepType } from "../src/workflow/registry.mjs";
import { GateStep } from "../src/workflow/steps/gate.mjs";

const ctx = (fields = {}) => new StepContext(fields);

Expand Down Expand Up @@ -754,8 +754,8 @@ steps:
// operator wrongly defaulted nulls — these tests pin the corrected behavior.

test("explicit null config values fail loudly, never silently default", async () => {
const { FanOutStep } = await import("../src/factory/steps/control.mjs");
const { IfThenStep } = await import("../src/factory/steps/control.mjs");
const { FanOutStep } = await import("../src/workflow/steps/control.mjs");
const { IfThenStep } = await import("../src/workflow/steps/control.mjs");

// fan-out: explicit `step: null` FAILS (upstream: get() does not default it).
let result = await new FanOutStep().execute(
Expand Down
6 changes: 3 additions & 3 deletions tests/workflow-state.test.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ import { mkdtempSync, rmSync, writeFileSync, readFileSync, existsSync } from "no
import { writeFileSync as fsWriteFileSync } from "node:fs";
import { tmpdir } from "node:os";
import { join } from "node:path";
import { WorkflowEngine, RunState, RunStatus, Lease, LeaseHeldError } from "../src/factory/engine.mjs";
import { STEP_REGISTRY } from "../src/factory/registry.mjs";
import { stateStart, stateAdvance, statePause, stateFail, stateShow } from "../src/factory/state.mjs";
import { WorkflowEngine, RunState, RunStatus, Lease, LeaseHeldError } from "../src/workflow/engine.mjs";
import { STEP_REGISTRY } from "../src/workflow/registry.mjs";
import { stateStart, stateAdvance, statePause, stateFail, stateShow } from "../src/workflow/state.mjs";

function makeProject() {
const dir = mkdtempSync(join(tmpdir(), "wf-state-"));
Expand Down
2 changes: 1 addition & 1 deletion tests/workflow-yaml.test.mjs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// YAML subset parser tests for factory workflow files.
import { test } from "node:test";
import assert from "node:assert/strict";
import { parseYaml } from "../src/factory/yaml.mjs";
import { parseYaml } from "../src/workflow/yaml.mjs";

test("workflow-shaped document parses fully", () => {
const doc = parseYaml(`
Expand Down
Loading