Skip to content

Scaffolding Wizard

The TAFLEX PY Modular framework includes an interactive, CLI-based Scaffolding Wizard (scaffold.sh) that dynamically generates a bespoke test automation project based on your specific requirements.

Instead of cloning a monolithic repository full of tools you don't need, the wizard asks you a series of questions and builds a lightweight, clean project tailored to your team's stack.

Fast Track

To generate a new project instantly, run the script from the root of the repository:

./scaffold.sh


Configuration Modules

The wizard allows you to build a custom tech stack. By selecting only what you need, you reduce dependency bloat.

1. Testing Domains

WEB

Playwright

Includes taflex.web and installs playwright dependencies. Select this for robust browser automation.

API

HTTPX

Includes taflex.api and installs httpx. Select this for high-speed, direct backend API tests.

MOBILE

Appium

Includes taflex.mobile and installs Appium-Python-Client. Select this for iOS/Android native app automation.

CONTRACT

Pact

Includes taflex.contract and installs pact-python. Select this for consumer-driven contract testing.

Default Fallback

If no specific testing modules are selected, the wizard defaults to setting up the Web Testing domain.

2. Reporting Stack

Next, the wizard configures your enterprise reporting stack:

📄 HTML Report

Generates a lightweight, single-file HTML report directly from pytest-html. Perfect for fast local debugging.

📊 Allure Report

Sets up allure-pytest integration for rich, interactive reporting. Includes a helper script to serve results locally.

🚀 ReportPortal

Sets up pytest-reportportal and populates the .env file with EPAM ReportPortal configurations.

🎯 Jira Xray

Sets up pytest-jira-xray to sync automated test results directly back to Jira Test Executions for full traceability.

3. CI/CD & Target Directory

  • CI/CD Pipelines: Automatically generates CI/CD configuration files (e.g., GitHub Actions ci.yml or GitLab CI .gitlab-ci.yml) optimized with caching and linting.
  • Target Directory: Define exactly where the new project should be generated (e.g., ./my-test-project).

What Gets Generated?

The wizard seamlessly creates a ready-to-run environment containing:

  1. Source Code (src/taflex/): Copies the core module and your selected domain modules.
  2. Build System (pyproject.toml): Dynamically populates dependencies and Pytest markers based on your selections.
  3. Environment (.env): Sets the primary EXECUTION_MODE and prepares relevant sections (e.g., APPIUM_SERVER_URL).
  4. Scaffolding (tests/ & docs/): Generates sample Page Objects, tests, local conftest.py, and custom documentation for your team.
  5. Quickstart Script (config.sh): A helper to instantly initialize the virtual environment, install dependencies, and download required binaries (like Playwright browsers).

Next Steps

Once the wizard completes, your new project is ready to execute:

cd my-test-project
source ./config.sh
pytest