Repository navigation
·
6 commits
to main
since this release
Structured Text Headless CLI Test Runner — v1.0.0
A standalone, headless test execution and verification engine engineered for IEC 61131-3 Structured Text control logic. Packaged as a standalone product executable for local terminal workflows and automated CI/CD build environments (GitHub Actions, GitLab CI, Jenkins).
Key Capabilities
- Headless Virtual PLC Simulation Engine:
- Executes multi-cycle simulation sweeps outside of an IDE or graphical desktop environment.
- Configurable scan cycle limits (
--max-cycles) and cycle step timings (--cycle-delta). - Native execution for standard library timers (such as
TON), counters, and edge detectors.
- Automated File & Test Discovery:
- Traverses target project directories and runs all test POUs matching naming conventions (programs prefixed with
TESTorPRG_TEST, or ending with_TEST)[cite: 3, 7]. - Integrated parsing and validation to catch syntax and unresolved reference errors before test execution.
- Traverses target project directories and runs all test POUs matching naming conventions (programs prefixed with
- CI/CD Pipeline Integration:
- Generates standardized JUnit XML reports (
TEST-plc-results.xml) ready for ingestion by CI test reporting tools. - Deterministic process exit codes: returns
0for passed suites and1for test assertions, license failures, or compilation errors.
- Generates standardized JUnit XML reports (
CLI Usage
Unpack the archive and invoke the executable directly:
# Basic run targeting a directory of .st files
st-test-runnercc --source-dir ./tests --report-dir ./build/test-results
# Advanced run specifying cycle limits, step intervals, and license key
st-test-runnercc --source-dir ./src --max-cycles 200 --cycle-delta 20 --license-key YOUR_KEY