---
description: CI/CD, flavours, and quality gates for TestApp
globs: [".github/**", "codemagic.yaml", "Makefile", "pubspec.yaml", "fastlane/**"]
alwaysApply: false
---

# CI/CD & flavours — TestApp

## Context
Pipeline and flavour setup must stay aligned with how the app is built and released.

## Flavours
- Documented in `project-brief.yaml`: **dev, prod**
- Use `--flavor` / `-t lib/main_<flavour>.dart` (or your project’s entrypoints) consistently across local, CI, and store builds
- Configuration via `--dart-define` / `--dart-define-from-file` — **never** hardcode secrets in source

## Quality gates (recommended stages)
- **Lint:** `dart format --set-exit-if-changed .` and `flutter analyze`
- **Unit + widget:** `flutter test` (with coverage if the team tracks it)
- **Goldens:** fixed device/locale; CI fails on drift unless intentionally updated
- **Smoke build:** e.g. `flutter build apk` or `flutter build ios --no-codesign` for the primary flavour
- **E2E:** when `testing.depth` includes e2e — patrol on CI devices or Firebase Test Lab

## Cursor integration
- After substantive edits: run analyze and relevant tests before PR
- For release-oriented tasks, use the **deploy** skill at `.cursor/skills/deploy/SKILL.md` when present

## CI/CD tool
- Selected in brief: **GitHub Actions** (`github_actions`)
