VIRIM Infotech
Your AI Assisted Product Developers

vm-ci-test-workflow-generator

Skill detail with category, linked agents, and source metadata.

vm-ci-test-workflow-generator

Generates two GitHub Actions workflow files from smoke and regression pack manifests: ci-smoke.yml (PR gate running smoke pack, blocks merge on failure) and ci-regression.yml (merge-to-main and nightly schedule running full regression pack). Supports Python/pytest, TypeScript/Vitest, and Playwright 8+. Adapted from HelloWorld-AgentSkills vm-build-deploy-test-workflow-generator and vm-check-workflow-generator.

Category: testing Used by 1 agents

Source: .github/skills/testing/vm-ci-test-workflow-generator/SKILL.md

Used By Agents

Preview

View source preview (first 3000 chars)

# VM CI Test Workflow Generator

> Adapted from: HelloWorld-AgentSkills `vm-build-deploy-test-workflow-generator` v1.0.0 and `vm-check-workflow-generator` v1.0.0

## Overview

Given smoke pack and regression pack manifests, this skill generates two GitHub Actions YAML workflow files:
1. **`ci-smoke.yml`** — Triggered on every pull request. Runs smoke pack only. Fails and blocks merge if any smoke test fails.
2. **`ci-regression.yml`** — Triggered on merge to `main`/`master` AND on a nightly cron schedule. Runs the full regression pack. Uploads test reports as artifacts.

If the test suite includes Playwright E2E tests, the workflows include Playwright browser dependency installation steps.

## Unitary Function

**ONE RESPONSIBILITY:** Produce GitHub Actions workflow YAML for PR smoke gating and scheduled full regression, derived from pack manifests.

**NOT RESPONSIBLE FOR:**
- Running or validating tests at spec time
- Generating test code (vm-test-suite-generator)
- Labeling test packs (vm-smoke-regression-packager)
- Deployment workflows (use vm-build-deploy-test-workflow-generator from HelloWorld baseline)

## Inputs

```json
{
  "smoke_pack_path": "docs/test-design/smoke-pack.json",
  "regression_pack_path": "docs/test-design/regression-pack.json",
  "tech_stack": {
    "language": "python|typescript|java|dotnet",
    "runtime_version": "3.12|22|21|8",
    "package_manager": "pip|npm|pnpm|maven|gradle|nuget",
    "test_framework_unit": "pytest|vitest|junit5|xunit",
    "playwright_required": true,
    "playwright_version": "8"
  },
  "output_path": ".github/workflows/",
  "nightly_schedule_cron": "0 2 * * *",
  "main_branch": "main"
}
```

## Generated Workflow: ci-smoke.yml

Load `assets/ci-smoke-workflow-template.yml` and substitute all `{placeholder}` tokens before writing to `.github/workflows/ci-smoke.yml`.


## Generated Workflow: ci-regression.yml

Load `assets/ci-regression-workflow-template.yml` and substitute all `{placeholder}` tokens before writing to `.github/workflows/ci-regression.yml`.

## Templates

| File | Purpose |
|---|---|
| `assets/ci-smoke-workflow-template.yml` | PR smoke gate — substitute `{runtime_version}`, `{unit_and_integration_smoke_file_args}`, `{e2e_smoke_file_args}` |
| `assets/ci-regression-workflow-template.yml` | Full regression suite — substitute `{runtime_version}`, `{nightly_schedule_cron}` |

## Security Requirements (Applied to All Generated Workflows)

- No hardcoded secrets — all credentials via `${{ secrets.SECRET_NAME }}` or `${{ secrets[vars.VAR_NAME] }}`
- Actions pinned to specific versions (`@v4`, `@v5`) — never `@latest` or `@main`
- Minimum required permissions declared (principle of least privilege)
- `GITHUB_TOKEN` only granted `contents: read` unless PR commenting is needed

## Output

```json
{
  "generated_by": {
    "skill": "vm-ci-test-workflow-generator",
    "version": "1.0.0"
  },
  "files_generated": [
    {
      "file": ".github/workflows/ci-smoke.yml",
      "trigger": "pull_