test(handlers/org): add unit tests for walkOrgWorkspaceNames, resolveProvisionConcurrency, errString #941

Merged
devops-engineer merged 1 commits from fix/org-helper-tests into main 2026-05-14 03:55:05 +00:00

1 Commits

Author SHA1 Message Date
424ffbdb43 test(handlers/org): add unit tests for walkOrgWorkspaceNames, resolveProvisionConcurrency, errString
Some checks are pending
sop-checklist / all-items-acked (pull_request) ok
CI / all-required (pull_request) ok
Block internal-flavored paths / Block forbidden paths (pull_request) Waiting to run
CI / Detect changes (pull_request) Waiting to run
CI / Platform (Go) (pull_request) Blocked by required conditions
CI / Canvas (Next.js) (pull_request) Blocked by required conditions
CI / Shellcheck (E2E scripts) (pull_request) Blocked by required conditions
CI / Canvas Deploy Reminder (pull_request) Blocked by required conditions
CI / Python Lint & Test (pull_request) Blocked by required conditions
E2E API Smoke Test / detect-changes (pull_request) Waiting to run
E2E API Smoke Test / E2E API Smoke Test (pull_request) Blocked by required conditions
E2E Staging Canvas (Playwright) / detect-changes (pull_request) Waiting to run
E2E Staging Canvas (Playwright) / Canvas tabs E2E (pull_request) Blocked by required conditions
Handlers Postgres Integration / detect-changes (pull_request) Waiting to run
Handlers Postgres Integration / Handlers Postgres Integration (pull_request) Blocked by required conditions
Harness Replays / detect-changes (pull_request) Waiting to run
Harness Replays / Harness Replays (pull_request) Blocked by required conditions
lint-required-no-paths / lint-required-no-paths (pull_request) Waiting to run
Runtime PR-Built Compatibility / detect-changes (pull_request) Waiting to run
Runtime PR-Built Compatibility / PR-built wheel + import smoke (pull_request) Blocked by required conditions
Secret scan / Scan diff for credential-shaped strings (pull_request) Waiting to run
gate-check-v3 / gate-check (pull_request) Waiting to run
qa-review / approved (pull_request) Waiting to run
security-review / approved (pull_request) Waiting to run
sop-checklist-gate / gate (pull_request) Waiting to run
sop-tier-check / tier-check (pull_request) Waiting to run
audit-force-merge / audit (pull_request) Waiting to run
Issue #741: three pure helpers in org.go had no unit tests.

Added 13 new test cases:
- walkOrgWorkspaceNames (6): empty, single node, nested children,
  skips empty names, deeply nested (5 levels), multiple roots.
- resolveProvisionConcurrency (6): default, valid positive int,
  zero (unlimited semantics), negative (falls back), non-integer
  (falls back), whitespace-trimmed.
- errString (3): nil error, non-nil error, wrapped error (%w).

Closes: molecule-ai/molecule-core#741

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-14 03:53:40 +00:00