| name | urunner-stdlib |
| description | Run ets_func_tests using the Universal Runner (urunner) tool. Use when executing stdlib tests, running test suites, or testing ETS functionality. Handles running tests with runner.sh from ../../../tests/tests-u-runner-2/, selecting workflows and test suites, configuring test options, and running specific tests or full test suites. |
Urunner Stdlib
Run ets_func_tests using the Universal Runner (urunner) tool.
Tool Location
- Runner directory:
../../../tests/tests-u-runner-2/
- Runner script:
runner.sh or main.py
- Configuration:
cfg/workflows/ and cfg/test-suites/
Prerequisites
- Panda build - Build must be completed (see build-stdlib skill)
- Python 3.8+ - 3.10 recommended
- Virtual environment - Created via
sudo static_core/scripts/install-deps-ubuntu -i=test
- Environment setup -
~/.urunner.env must exist with required variables
Environment Variables
Create ~/.urunner.env:
ARKCOMPILER_RUNTIME_CORE_PATH=<path to arkcompiler_runtime_core>
ARKCOMPILER_ETS_FRONTEND_PATH=<path to arkcompiler_ets_frontend>
PANDA_BUILD=<path to build folder>
WORK_DIR=<path to temporary working folder>
Or run: ./runner.sh init for interactive setup.
Quick Start
From stdlib directory (stdlib/):
Always use --filter option to filter affected api, to check which tests are affected need to check ../tests/ets_func_tests/std/.
Example: --filter **/std/core/json if changed json api. If changed Intl need to use --filter **/std/core/Intl*.
cd ../../../tests/tests-u-runner-2/
./runner.sh panda-int ets-func-tests --show-progress --force-generate --processes=all --verbose=short --filter **/std/core/json`
cd ../../../tests/tests-u-runner-2/
./runner.sh panda-int ets-func-tests ets-es-checked --show-progress --force-generate --processes=all --verbose=short
./runner.sh panda-int ets-func-tests --show-progress --force-generate --verbose=short
Basic Usage
Standard Test Run
cd ../../../tests/tests-u-runner-2/
./runner.sh <workflow> <test-suite> [options]
Common Workflows
From cfg/workflows/:
panda-int - Panda interpreter (most common for stdlib)
panda-aot - Panda AOT compilation
ark - ARK runtime
checker - Type checker only
Test Suite for Stdlib
The stdlib tests are typically run with:
- Test suite:
ets-func-tests (may vary, check cfg/test-suites/)
Running Specific Tests
Filter Tests
./runner.sh panda-int ets-func-tests --verbose=short --test-file StringCharAtTest.ets
./runner.sh panda-int ets-func-tests --verbose=short --filter "**/String*"
./runner.sh panda-int ets-func-tests --verbose=short --filter "**/core/*" --filter "**/containers/*"
Test Directory
./runner.sh panda-int ets-func-tests --test-dir core/
Common Options
--show-progress
--processes <N>
--force-generate
--extension ets
--load-runtimes ets
--opt-level 2
--timeout <N>
Examples
Run All Stdlib Tests
cd ../../../tests/tests-u-runner-2/
./runner.sh panda-int ets-func-tests --show-progress --verbose=short
Run Specific Test File
./runner.sh panda-int ets-func-tests --verbose=short --test-file StringGetTest.ets
Run With Custom Options
./runner.sh panda-int ets-func-tests \
--show-progress \
--processes 4 \
--verbose=short \
--force-generate
Run Tests Matching Pattern
./runner.sh panda-int ets-func-tests --filter "**String*"
Output and Results
- Reports: Generated in
$WORK_DIR/reports/
- Logs: Available in work directory
- Exit codes: 0 = success, non-zero = failures
Troubleshooting
Environment Not Set Up
./runner.sh init
Virtual Environment Missing
sudo static_core/scripts/install-deps-ubuntu -i=test
Build Not Found
cd ../../../
cmake -B build -DCMAKE_BUILD_TYPE=Release -GNinja \
-DCMAKE_TOOLCHAIN_FILE=cmake/toolchain/host_clang_14.cmake \
-S . -Werror=dev -DPANDA_WITH_TESTS=ON\
-DPANDA_ETS_INTEROP_JS=ON
cmake --build build --target panda_bins etssdk
Direct Python Usage
If preferred, run main.py directly:
cd ../../../tests/tests-u-runner-2/
source ~/.venv-panda/bin/activate
python3 main.py panda-int ets-func-tests --show-progress
deactivate
Rebuilding Stdlib After .ets Changes
CRITICAL: When you modify .ets files in the stdlib, you must rebuild the boot stdlib that the runtime uses at test execution time:
| Target | Output | Used by | Command |
|---|
etsstdlib | build/plugins/ets/etsstdlib.abc | Runtime boot stdlib (--boot-panda-files) | ninja plugins/ets/etsstdlib |
When tests fail with unexpected behavior after .ets changes, it is almost always because etsstdlib.abc is stale.
Best practice: After modifying any .ets stdlib file, always rebuild:
cd ../../../build/
ninja -j$(nproc) plugins/ets/etsstdlib
To verify freshness:
ls -la build/plugins/ets/etsstdlib.abc