qa-mcp 1.0.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. qa_mcp-1.0.0/.dockerignore +64 -0
  2. qa_mcp-1.0.0/.github/RELEASE_TEMPLATE.md +53 -0
  3. qa_mcp-1.0.0/.github/workflows/ci.yml +130 -0
  4. qa_mcp-1.0.0/.github/workflows/dockerhub-description.yml +28 -0
  5. qa_mcp-1.0.0/.github/workflows/publish-pypi.yml +90 -0
  6. qa_mcp-1.0.0/.github/workflows/release.yml +133 -0
  7. qa_mcp-1.0.0/.github/workflows/security.yml +122 -0
  8. qa_mcp-1.0.0/.gitignore +154 -0
  9. qa_mcp-1.0.0/.pre-commit-config.yaml +63 -0
  10. qa_mcp-1.0.0/CHANGELOG.md +58 -0
  11. qa_mcp-1.0.0/CONTRIBUTING.md +320 -0
  12. qa_mcp-1.0.0/DOCKERHUB.md +107 -0
  13. qa_mcp-1.0.0/Dockerfile +54 -0
  14. qa_mcp-1.0.0/LICENSE +21 -0
  15. qa_mcp-1.0.0/PKG-INFO +443 -0
  16. qa_mcp-1.0.0/README.md +406 -0
  17. qa_mcp-1.0.0/USAGE.md +673 -0
  18. qa_mcp-1.0.0/docker-compose.yml +66 -0
  19. qa_mcp-1.0.0/docs/PUBLISHING.md +209 -0
  20. qa_mcp-1.0.0/pyproject.toml +88 -0
  21. qa_mcp-1.0.0/resources/checklists/lint_rules_v1.json +248 -0
  22. qa_mcp-1.0.0/resources/examples/bad/too_long_testcase.json +89 -0
  23. qa_mcp-1.0.0/resources/examples/bad/vague_testcase.json +68 -0
  24. qa_mcp-1.0.0/resources/examples/good/api_negative.json +89 -0
  25. qa_mcp-1.0.0/resources/examples/good/login_positive.json +101 -0
  26. qa_mcp-1.0.0/resources/mappings/xray_v1.json +182 -0
  27. qa_mcp-1.0.0/resources/standards/testcase_v1.json +235 -0
  28. qa_mcp-1.0.0/src/qa_mcp/__init__.py +8 -0
  29. qa_mcp-1.0.0/src/qa_mcp/core/__init__.py +29 -0
  30. qa_mcp-1.0.0/src/qa_mcp/core/lint.py +495 -0
  31. qa_mcp-1.0.0/src/qa_mcp/core/models.py +207 -0
  32. qa_mcp-1.0.0/src/qa_mcp/core/standards.py +302 -0
  33. qa_mcp-1.0.0/src/qa_mcp/prompts/__init__.py +17 -0
  34. qa_mcp-1.0.0/src/qa_mcp/prompts/templates.py +283 -0
  35. qa_mcp-1.0.0/src/qa_mcp/resources/__init__.py +17 -0
  36. qa_mcp-1.0.0/src/qa_mcp/resources/standards.py +570 -0
  37. qa_mcp-1.0.0/src/qa_mcp/server.py +625 -0
  38. qa_mcp-1.0.0/src/qa_mcp/tools/__init__.py +16 -0
  39. qa_mcp-1.0.0/src/qa_mcp/tools/compose.py +485 -0
  40. qa_mcp-1.0.0/src/qa_mcp/tools/generate.py +475 -0
  41. qa_mcp-1.0.0/src/qa_mcp/tools/lint.py +189 -0
  42. qa_mcp-1.0.0/src/qa_mcp/tools/normalize.py +465 -0
  43. qa_mcp-1.0.0/src/qa_mcp/tools/to_xray.py +315 -0
  44. qa_mcp-1.0.0/tests/__init__.py +1 -0
  45. qa_mcp-1.0.0/tests/conftest.py +85 -0
  46. qa_mcp-1.0.0/tests/test_lint.py +150 -0
  47. qa_mcp-1.0.0/tests/test_models.py +145 -0
  48. qa_mcp-1.0.0/tests/test_tools.py +316 -0
  49. qa_mcp-1.0.0/uv.lock +1410 -0
@@ -0,0 +1,64 @@
1
+ # Git
2
+ .git
3
+ .gitignore
4
+
5
+ # Python
6
+ __pycache__
7
+ *.py[cod]
8
+ *$py.class
9
+ *.so
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ *.egg-info/
24
+ .installed.cfg
25
+ *.egg
26
+
27
+ # Virtual environments
28
+ .venv
29
+ venv/
30
+ ENV/
31
+ env/
32
+
33
+ # IDE
34
+ .idea/
35
+ .vscode/
36
+ *.swp
37
+ *.swo
38
+ *~
39
+
40
+ # Testing
41
+ .pytest_cache/
42
+ .coverage
43
+ htmlcov/
44
+ .tox/
45
+ .nox/
46
+
47
+ # Documentation
48
+ docs/_build/
49
+ *.md
50
+ !README.md
51
+
52
+ # CI/CD
53
+ .github/
54
+
55
+ # Docker
56
+ Dockerfile*
57
+ docker-compose*.yml
58
+ .dockerignore
59
+
60
+ # Misc
61
+ .DS_Store
62
+ *.log
63
+ .env
64
+ .env.*
@@ -0,0 +1,53 @@
1
+ # QA-MCP v{VERSION} Release
2
+
3
+ ## 🎉 Highlights
4
+
5
+ {Brief summary of key features/improvements in this release}
6
+
7
+ ## 📦 Installation
8
+
9
+ ### Using pip
10
+ ```bash
11
+ pip install qa-mcp=={VERSION}
12
+ ```
13
+
14
+ ### Using uv (recommended)
15
+ ```bash
16
+ uv pip install qa-mcp=={VERSION}
17
+ ```
18
+
19
+ ### Using Docker
20
+ ```bash
21
+ docker pull atakanemree/qa-mcp:{VERSION}
22
+ docker run -i --rm atakanemree/qa-mcp:{VERSION}
23
+ ```
24
+
25
+ ### From source
26
+ ```bash
27
+ git clone --branch v{VERSION} https://github.com/Atakan-Emre/McpTestGenerator.git
28
+ cd McpTestGenerator
29
+ pip install -e .
30
+ ```
31
+
32
+ ## 🔄 Changes
33
+
34
+ See the [CHANGELOG](https://github.com/Atakan-Emre/McpTestGenerator/blob/main/CHANGELOG.md#v{VERSION_ANCHOR}) for detailed changes.
35
+
36
+ ## ⚠️ Breaking Changes
37
+
38
+ {List any breaking changes, or write "None" if there are no breaking changes}
39
+
40
+ ## 📚 Documentation
41
+
42
+ - [README](https://github.com/Atakan-Emre/McpTestGenerator#readme)
43
+ - [Usage Guide](https://github.com/Atakan-Emre/McpTestGenerator/blob/main/USAGE.md)
44
+ - [Contributing](https://github.com/Atakan-Emre/McpTestGenerator/blob/main/CONTRIBUTING.md)
45
+ - [Docker Hub](https://hub.docker.com/r/atakanemree/qa-mcp)
46
+
47
+ ## 🙏 Contributors
48
+
49
+ Thanks to all contributors who made this release possible!
50
+
51
+ ---
52
+
53
+ **Full Changelog**: https://github.com/Atakan-Emre/McpTestGenerator/compare/v{PREV_VERSION}...v{VERSION}
@@ -0,0 +1,130 @@
1
+ # QA-MCP Continuous Integration
2
+ # Runs on every push and pull request
3
+
4
+ name: CI
5
+
6
+ on:
7
+ push:
8
+ branches: [main, develop]
9
+ pull_request:
10
+ branches: [main]
11
+
12
+ env:
13
+ PYTHON_VERSION: "3.11"
14
+
15
+ jobs:
16
+ # ==========================================================================
17
+ # Code Quality
18
+ # ==========================================================================
19
+ lint:
20
+ name: Lint & Type Check
21
+ runs-on: ubuntu-latest
22
+ steps:
23
+ - uses: actions/checkout@v4
24
+
25
+ - name: Set up Python
26
+ uses: actions/setup-python@v5
27
+ with:
28
+ python-version: ${{ env.PYTHON_VERSION }}
29
+
30
+ - name: Install dependencies
31
+ run: |
32
+ python -m pip install --upgrade pip
33
+ pip install ruff mypy
34
+ pip install -e .
35
+
36
+ - name: Run Ruff (linting)
37
+ run: ruff check src/
38
+
39
+ - name: Run Ruff (formatting)
40
+ run: ruff format --check src/
41
+
42
+ - name: Run MyPy (type checking)
43
+ run: mypy src/qa_mcp --ignore-missing-imports
44
+ continue-on-error: true
45
+
46
+ # ==========================================================================
47
+ # Tests
48
+ # ==========================================================================
49
+ test:
50
+ name: Test (Python ${{ matrix.python-version }})
51
+ runs-on: ubuntu-latest
52
+ strategy:
53
+ matrix:
54
+ python-version: ["3.11", "3.12"]
55
+ steps:
56
+ - uses: actions/checkout@v4
57
+
58
+ - name: Set up Python ${{ matrix.python-version }}
59
+ uses: actions/setup-python@v5
60
+ with:
61
+ python-version: ${{ matrix.python-version }}
62
+
63
+ - name: Install dependencies
64
+ run: |
65
+ python -m pip install --upgrade pip
66
+ pip install -e ".[dev]"
67
+
68
+ - name: Run tests
69
+ run: |
70
+ pytest tests/ -v --cov=qa_mcp --cov-report=xml --cov-report=html
71
+
72
+ - name: Upload coverage to Codecov
73
+ uses: codecov/codecov-action@v4
74
+ if: matrix.python-version == '3.11'
75
+ with:
76
+ file: ./coverage.xml
77
+ fail_ci_if_error: false
78
+
79
+ # ==========================================================================
80
+ # Security Scan
81
+ # ==========================================================================
82
+ security:
83
+ name: Security Scan
84
+ runs-on: ubuntu-latest
85
+ steps:
86
+ - uses: actions/checkout@v4
87
+
88
+ - name: Set up Python
89
+ uses: actions/setup-python@v5
90
+ with:
91
+ python-version: ${{ env.PYTHON_VERSION }}
92
+
93
+ - name: Install dependencies
94
+ run: |
95
+ python -m pip install --upgrade pip
96
+ pip install bandit safety
97
+
98
+ - name: Run Bandit (security linter)
99
+ run: bandit -r src/qa_mcp -ll
100
+
101
+ - name: Check dependencies for vulnerabilities
102
+ run: |
103
+ pip install -e .
104
+ safety check --full-report || true
105
+
106
+ # ==========================================================================
107
+ # Docker Build Test
108
+ # ==========================================================================
109
+ docker-build:
110
+ name: Docker Build Test
111
+ runs-on: ubuntu-latest
112
+ steps:
113
+ - uses: actions/checkout@v4
114
+
115
+ - name: Set up Docker Buildx
116
+ uses: docker/setup-buildx-action@v3
117
+
118
+ - name: Build Docker image
119
+ uses: docker/build-push-action@v5
120
+ with:
121
+ context: .
122
+ push: false
123
+ load: true
124
+ tags: atakanemree/qa-mcp:test
125
+ cache-from: type=gha
126
+ cache-to: type=gha,mode=max
127
+
128
+ - name: Test Docker image
129
+ run: |
130
+ docker run --rm atakanemree/qa-mcp:test --help
@@ -0,0 +1,28 @@
1
+ # Docker Hub Description Sync
2
+ # Syncs DOCKERHUB.md to Docker Hub repository description
3
+
4
+ name: Docker Hub Description
5
+
6
+ on:
7
+ push:
8
+ branches: [main]
9
+ paths:
10
+ - 'DOCKERHUB.md'
11
+ workflow_dispatch:
12
+
13
+ jobs:
14
+ update-description:
15
+ name: Update Docker Hub Description
16
+ runs-on: ubuntu-latest
17
+ steps:
18
+ - name: Checkout
19
+ uses: actions/checkout@v4
20
+
21
+ - name: Update Docker Hub Description
22
+ uses: peter-evans/dockerhub-description@v4
23
+ with:
24
+ username: ${{ secrets.DOCKERHUB_USERNAME }}
25
+ password: ${{ secrets.DOCKERHUB_TOKEN }}
26
+ repository: atakanemree/qa-mcp
27
+ readme-filepath: ./DOCKERHUB.md
28
+ short-description: "QA-MCP: Test Standardization & Orchestration MCP Server for LLM clients"
@@ -0,0 +1,90 @@
1
+ # Publish to PyPI
2
+ # This workflow automatically publishes the package to PyPI when a new release is created
3
+
4
+ name: Publish to PyPI
5
+
6
+ on:
7
+ release:
8
+ types: [published]
9
+ workflow_dispatch:
10
+ inputs:
11
+ publish_target:
12
+ description: "Publish destination"
13
+ required: true
14
+ default: testpypi
15
+ type: choice
16
+ options:
17
+ - testpypi
18
+ - pypi
19
+
20
+ permissions:
21
+ contents: read
22
+
23
+ jobs:
24
+ build-and-publish:
25
+ name: Build and publish to PyPI
26
+ runs-on: ubuntu-latest
27
+
28
+ steps:
29
+ - name: Checkout code
30
+ uses: actions/checkout@v4
31
+
32
+ - name: Set up Python
33
+ uses: actions/setup-python@v5
34
+ with:
35
+ python-version: '3.11'
36
+
37
+ - name: Install build dependencies
38
+ run: |
39
+ python -m pip install --upgrade pip
40
+ pip install build twine
41
+
42
+ - name: Build package
43
+ run: python -m build
44
+
45
+ - name: Check package
46
+ run: twine check dist/*
47
+
48
+ - name: Resolve package version
49
+ run: |
50
+ python - <<'PY'
51
+ import tomllib
52
+ from pathlib import Path
53
+
54
+ pyproject = Path("pyproject.toml")
55
+ version = tomllib.loads(pyproject.read_text())["project"]["version"]
56
+ print(f"PACKAGE_VERSION={version}")
57
+ with open("/tmp/package_version.env", "w") as f:
58
+ f.write(f"PACKAGE_VERSION={version}\n")
59
+ PY
60
+ cat /tmp/package_version.env >> "$GITHUB_ENV"
61
+
62
+ - name: Resolve publish target
63
+ run: |
64
+ if [ "${{ github.event_name }}" = "release" ]; then
65
+ echo "PUBLISH_TARGET=pypi" >> "$GITHUB_ENV"
66
+ else
67
+ echo "PUBLISH_TARGET=${{ github.event.inputs.publish_target }}" >> "$GITHUB_ENV"
68
+ fi
69
+
70
+ - name: Publish to Test PyPI
71
+ if: env.PUBLISH_TARGET == 'testpypi'
72
+ env:
73
+ TWINE_USERNAME: __token__
74
+ TWINE_PASSWORD: ${{ secrets.TEST_PYPI_API_TOKEN }}
75
+ run: |
76
+ twine upload --repository testpypi dist/* --skip-existing
77
+
78
+ - name: Publish to PyPI
79
+ if: env.PUBLISH_TARGET == 'pypi'
80
+ env:
81
+ TWINE_USERNAME: __token__
82
+ TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
83
+ run: |
84
+ twine upload dist/*
85
+
86
+ - name: Verify PyPI upload
87
+ if: env.PUBLISH_TARGET == 'pypi'
88
+ run: |
89
+ sleep 60 # Wait for PyPI to process
90
+ pip install qa-mcp==${PACKAGE_VERSION} || echo "Package may still be processing on PyPI"
@@ -0,0 +1,133 @@
1
+ # QA-MCP Release Pipeline
2
+ # Builds and publishes multi-arch Docker images to Docker Hub
3
+ # Triggered on version tags (v*.*.*)
4
+
5
+ name: Release
6
+
7
+ on:
8
+ push:
9
+ tags:
10
+ - 'v*.*.*'
11
+
12
+ env:
13
+ REGISTRY: docker.io
14
+ IMAGE_NAME: atakanemree/qa-mcp
15
+
16
+ jobs:
17
+ # ==========================================================================
18
+ # Build and Push Multi-Arch Docker Image
19
+ # ==========================================================================
20
+ docker-publish:
21
+ name: Build & Push Docker Image
22
+ runs-on: ubuntu-latest
23
+ permissions:
24
+ contents: read
25
+ packages: write
26
+ id-token: write # For SBOM signing
27
+ steps:
28
+ - uses: actions/checkout@v4
29
+
30
+ - name: Set up QEMU (for multi-arch)
31
+ uses: docker/setup-qemu-action@v3
32
+
33
+ - name: Set up Docker Buildx
34
+ uses: docker/setup-buildx-action@v3
35
+
36
+ - name: Log in to Docker Hub
37
+ uses: docker/login-action@v3
38
+ with:
39
+ registry: ${{ env.REGISTRY }}
40
+ username: ${{ secrets.DOCKERHUB_USERNAME }}
41
+ password: ${{ secrets.DOCKERHUB_TOKEN }}
42
+
43
+ - name: Extract metadata
44
+ id: meta
45
+ uses: docker/metadata-action@v5
46
+ with:
47
+ images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
48
+ tags: |
49
+ # Semantic versioning tags
50
+ type=semver,pattern={{version}}
51
+ type=semver,pattern={{major}}.{{minor}}
52
+ type=semver,pattern={{major}}
53
+ # Latest tag for newest release
54
+ type=raw,value=latest
55
+
56
+ - name: Extract version from tag
57
+ id: version
58
+ run: echo "VERSION=${GITHUB_REF_NAME#v}" >> $GITHUB_OUTPUT
59
+
60
+ - name: Build and push multi-arch image
61
+ uses: docker/build-push-action@v5
62
+ with:
63
+ context: .
64
+ platforms: linux/amd64,linux/arm64
65
+ push: true
66
+ tags: ${{ steps.meta.outputs.tags }}
67
+ labels: ${{ steps.meta.outputs.labels }}
68
+ cache-from: type=gha
69
+ cache-to: type=gha,mode=max
70
+ # SBOM and provenance for supply chain security
71
+ sbom: true
72
+ provenance: mode=max
73
+
74
+ - name: Generate SBOM
75
+ uses: anchore/sbom-action@v0
76
+ with:
77
+ image: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.version.outputs.VERSION }}
78
+ format: spdx-json
79
+ output-file: sbom.spdx.json
80
+
81
+ - name: Upload SBOM artifact
82
+ uses: actions/upload-artifact@v4
83
+ with:
84
+ name: sbom
85
+ path: sbom.spdx.json
86
+
87
+ # ==========================================================================
88
+ # Create GitHub Release
89
+ # ==========================================================================
90
+ github-release:
91
+ name: Create GitHub Release
92
+ needs: docker-publish
93
+ runs-on: ubuntu-latest
94
+ permissions:
95
+ contents: write
96
+ steps:
97
+ - uses: actions/checkout@v4
98
+
99
+ - name: Download SBOM
100
+ uses: actions/download-artifact@v4
101
+ with:
102
+ name: sbom
103
+
104
+ - name: Extract version from tag
105
+ id: version
106
+ run: echo "VERSION=${GITHUB_REF_NAME#v}" >> $GITHUB_OUTPUT
107
+
108
+ - name: Create Release
109
+ uses: softprops/action-gh-release@v1
110
+ with:
111
+ name: QA-MCP v${{ steps.version.outputs.VERSION }}
112
+ body: |
113
+ ## QA-MCP v${{ steps.version.outputs.VERSION }}
114
+
115
+ ### Docker Image
116
+ ```bash
117
+ docker pull atakanemree/qa-mcp:${{ steps.version.outputs.VERSION }}
118
+ ```
119
+
120
+ ### Multi-arch Support
121
+ - `linux/amd64` (Intel/AMD)
122
+ - `linux/arm64` (Apple Silicon, ARM servers)
123
+
124
+ ### Changelog
125
+ See [CHANGELOG.md](CHANGELOG.md) for details.
126
+
127
+ ### Supply Chain Security
128
+ - SBOM included (SPDX format)
129
+ - Provenance attestation enabled
130
+ files: |
131
+ sbom.spdx.json
132
+ generate_release_notes: true
133
+
@@ -0,0 +1,122 @@
1
+ # QA-MCP Security Scanning
2
+ # Weekly security scans and on push to main
3
+
4
+ name: Security
5
+
6
+ on:
7
+ push:
8
+ branches: [main]
9
+ schedule:
10
+ # Run weekly on Monday at 00:00 UTC
11
+ - cron: '0 0 * * 1'
12
+ workflow_dispatch:
13
+
14
+ jobs:
15
+ # ==========================================================================
16
+ # Dependency Vulnerability Scan
17
+ # ==========================================================================
18
+ dependency-scan:
19
+ name: Dependency Scan
20
+ runs-on: ubuntu-latest
21
+ steps:
22
+ - uses: actions/checkout@v4
23
+
24
+ - name: Set up Python
25
+ uses: actions/setup-python@v5
26
+ with:
27
+ python-version: "3.11"
28
+
29
+ - name: Install dependencies
30
+ run: |
31
+ python -m pip install --upgrade pip
32
+ pip install safety pip-audit
33
+ pip install -e .
34
+
35
+ - name: Run Safety check
36
+ run: safety check --full-report
37
+ continue-on-error: true
38
+
39
+ - name: Run pip-audit
40
+ run: pip-audit
41
+ continue-on-error: true
42
+
43
+ # ==========================================================================
44
+ # Container Security Scan
45
+ # ==========================================================================
46
+ container-scan:
47
+ name: Container Security Scan
48
+ runs-on: ubuntu-latest
49
+ permissions:
50
+ actions: read
51
+ contents: read
52
+ security-events: write
53
+ steps:
54
+ - uses: actions/checkout@v4
55
+
56
+ - name: Set up Docker Buildx
57
+ uses: docker/setup-buildx-action@v3
58
+
59
+ - name: Build image for scanning
60
+ uses: docker/build-push-action@v5
61
+ with:
62
+ context: .
63
+ push: false
64
+ load: true
65
+ tags: atakanemree/qa-mcp:scan
66
+
67
+ - name: Run Trivy vulnerability scanner
68
+ uses: aquasecurity/trivy-action@master
69
+ with:
70
+ image-ref: 'atakanemree/qa-mcp:scan'
71
+ format: 'sarif'
72
+ output: 'trivy-results.sarif'
73
+ severity: 'CRITICAL,HIGH'
74
+ continue-on-error: true
75
+
76
+ - name: Upload Trivy scan results
77
+ uses: github/codeql-action/upload-sarif@v3
78
+ if: always()
79
+ with:
80
+ sarif_file: 'trivy-results.sarif'
81
+ continue-on-error: true
82
+
83
+ # ==========================================================================
84
+ # Code Security Analysis (CodeQL)
85
+ # ==========================================================================
86
+ codeql:
87
+ name: CodeQL Analysis
88
+ runs-on: ubuntu-latest
89
+ permissions:
90
+ actions: read
91
+ contents: read
92
+ security-events: write
93
+ steps:
94
+ - uses: actions/checkout@v4
95
+
96
+ - name: Initialize CodeQL
97
+ uses: github/codeql-action/init@v3
98
+ with:
99
+ languages: python
100
+ queries: security-and-quality
101
+
102
+ - name: Perform CodeQL Analysis
103
+ uses: github/codeql-action/analyze@v3
104
+ with:
105
+ category: "/language:python"
106
+
107
+ # ==========================================================================
108
+ # Secret Scanning
109
+ # ==========================================================================
110
+ secret-scan:
111
+ name: Secret Scanning
112
+ runs-on: ubuntu-latest
113
+ steps:
114
+ - uses: actions/checkout@v4
115
+ with:
116
+ fetch-depth: 0
117
+
118
+ - name: Run Gitleaks
119
+ uses: gitleaks/gitleaks-action@v2
120
+ env:
121
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
122
+ continue-on-error: true