Python, PyTest & SQL Foundations for AI QE Β· Day 7 Capstone Β· 25 min
Reusable AI Test Practice CI/CD Gate
Python, PyTest & SQL Foundations for AI QE β Day 7
Unify PyTest JUnit XML results, SQLite3 golden-dataset leakage and foreign-key checks, and per-category rubric thresholds into a single deterministic Azure DevOps & GitHub Actions release gate.
π¦Sample Codebase & Working Solution (Day 7)Available Now
View on GitHubThe official reference codebase for Day 7 is hosted in the repository. Clone the repository and navigate to day-7-pytest-ci-gate/gate.py to run the working solution.
Git Clone β Working Solution
git clone https://github.com/777abhi/pytest-sql-ai-qe-roadmap.git
cd pytest-sql-ai-qe-roadmap/day-7-pytest-ci-gate/gate.pyπProduction Context
π‘ Why We Are Doing This: Running isolated test scripts locally does not protect production releases. A single CLI gate aggregating PyTest JUnit XML, SQL dataset checks, and golden pass rates enforces objective go/no-go governance.
π’ Real-World Production Usecase: Automated pull-request and pre-release gate in Azure DevOps and GitHub Actions publishing JUnit XML and gate-report.json.
βοΈ How Implemented in Production: day-7-pytest-ci-gate/gate.py runs Days 1-6 via PyTest, parses JUnit XML, audits SQLite integrity, evaluates golden datasets, writes gate-report.json, and exits 0 (OPEN) or 1 (CLOSED).
Phase 1
Run Full 7-Day PyTest Suite & CI/CD Release Gate
Step 1.1: Run All 7 Days & Release Gate CLI
Terminal β Capstone Gate
./run_all.sh
python3 day-7-pytest-ci-gate/gate.pyStep 1.2: Ready-to-Use CI/CD Pipeline Templates
CI/CD Pipeline Files
# Azure DevOps
azure-pipelines.yml
# GitHub Actions
.github/workflows/pytest-ai-gate.ymlTrack Capstone Achieved
- Unified all 6 Python, PyTest & SQLite3 AI QE pillars into a single deterministic CI/CD release gate.
- Published JUnit XML and machine-readable gate-report.json verdicts with explicit blocking_reasons for Azure DevOps and GitHub Actions.
π§ Knowledge Check
What must day-7-pytest-ci-gate/gate.py do when it detects a PyTest failure, SQL train/eval leakage, or a vulnerable-user threshold breach?