Back to TresekoView full library

Automation workers

How to connect workers, declare capabilities and handle uncommon language runtimes.

Practical guide

1 guide found

All guides

Automation workers

How to connect workers, declare capabilities and handle uncommon language runtimes.

Open guide
Reading
11 min
Updated
2026-07-12
Version
1.0.6

When to use this guide

Use it when you want to run automated tests outside the manual Treseko browser, or when your team uses a runtime not included in the default worker.

Expected result

A worker linked to a solution, visible in Automation > Workers, with active heartbeat and clear capabilities to only take compatible jobs.

Tresekofrozen test casepending jobevidence
pairing WKrunner tokenheartbeat
Worker
Playwright JS/TSCypress JS/TSPuppeteer JS/TSSelenium PythonSpecialized runtime

Treseko keeps the source of truth: test cases, builds, datasets, variables, results and evidence. The worker does not replace that traceability; it only picks up a frozen job, executes it and returns the result.

The default worker covers the common paths: Playwright, Puppeteer and Cypress in JavaScript/TypeScript, and Selenium in Python. For Java, C#, Ruby or other stacks, the correct strategy is to spin up a specialized worker that announces those capabilities or report results via the external API.

The worker identity is not an IP or an open port. The worker communicates by pull against the backend, gets a token after approving the binding code, then sends heartbeat, picks up jobs and reports results with that token.

If the language is unusual, do not force it on a runner that does not support it. Define the runtime on the worker machine, declare it in capabilities and let Treseko only deliver jobs when framework and language match.

Recommended flow

  1. Install worker dependencies on the machine that will run tests.
  2. Configure QA_API_BASE, QA_ORGANIZACION_ID, name, tags and headless mode.
  3. Start the worker and copy the temporary code WK-xxxxxx.
  4. Approve the code from Automation > Workers.
  5. Confirm the worker is active, with recent heartbeat and visible capabilities.
  6. Create or edit an automated test case with compatible framework and language.
  7. Run the test case and review status, logs, artifacts and associated evidence.
  8. For special runtimes, create a dedicated profile and announce framework_languages.

Multi-framework local worker

cd automation-worker
npm install
npm run install:browsers
cp .env.example .env
# editar .env antes de iniciar
npm start

Minimal variables

QA_API_BASE=http://localhost:8000
QA_RUNNER_NAME=Linux Multi-Framework Worker
QA_ORGANIZACION_ID=uuid-de-la-solucion
QA_HEADLESS=true
QA_RUNNER_TAGS=linux,v1,playwright,puppeteer,cypress,selenium

Selenium Python

cd automation-worker
python3 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip selenium
realpath .venv/bin/python
# usar esa ruta en QA_PYTHON_BIN

Optional Docker profile

docker compose -f docker-compose.prod.yml --env-file compose.production.env --profile automation up -d automation-worker

How to verify

  • The UI shows the worker as linked with recent heartbeat.
  • The worker declares real frameworks and languages, not aspirational ones.
  • A compatible Playwright, Cypress, Puppeteer or Selenium job goes from PENDING to CLAIMED and then to PASSED, FAILED or ERROR.
  • Screenshots, logs or files reported by the worker appear as automation evidence.
  • A test case with an unsupported language does not end up half-executed: it must wait for a compatible runner or fail with a clear actionable message.

Common pitfalls

  • Not configuring QA_ORGANIZACION_ID and expecting the worker to be global for the whole instance.
  • Copying a runner token manually across multiple hosts and losing identity control.
  • Announcing Java, C# or Ruby without installing JDK, .NET SDK, Ruby/Bundler or required drivers on the worker machine.
  • Opening incoming ports to the worker even though the operational model is pull from worker to Treseko.
  • Mixing scripts, credentials and test data in worker code instead of using variables, datasets and operational secrets.
workerautomationplaywrightseleniumcypresslenguajes