refactor: Make tddai framework project-agnostic and fix test configuration

FRAMEWORK DECOUPLING:
- Remove all MarkiTect-specific references from tddai core modules
- Update tddai-assistant.md to use generic examples and language
- Change CLI output from "MarkiTect Issues" to "Project Issues"
- Update coverage_analyzer.py docstring to be project-neutral

CONFIGURATION SYSTEM:
- Make tddai configuration flexible via environment variables
- Add comprehensive documentation for project setup in config.py
- Create .env.tddai and tddai-setup.sh for MarkiTect-specific config
- Support configurable workspace naming (.tddai_workspace default)

TEST INFRASTRUCTURE CLEANUP:
- Fix IssueWriter test failures caused by config validation changes
- Implement _get_test_config() helper for isolated test configurations
- Ensure all 13 IssueWriter tests pass with proper test patterns
- Maintain clean test separation and project independence

FRAMEWORK PORTABILITY:
- TDD8 methodology now completely generic and reusable
- Configuration examples for GitHub/GitLab integration
- Ready for extraction to separate repository when needed
- All 45 tests pass cleanly confirming successful refactoring

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-09-24 00:04:54 +02:00
parent ef81266eb1
commit 0053fa68ec
8 changed files with 134 additions and 55 deletions

View File

@@ -1,5 +1,21 @@
"""
Configuration management for tddai.
The tddai framework is project-agnostic and can be configured per project
via environment variables:
- TDDAI_WORKSPACE_DIR: Workspace directory name (default: .tddai_workspace)
- TDDAI_GITEA_URL: Git platform URL
- TDDAI_REPO_OWNER: Repository owner/organization
- TDDAI_REPO_NAME: Repository name
Example .env file for a project:
```
TDDAI_WORKSPACE_DIR=.myproject_workspace
TDDAI_GITEA_URL=https://github.com
TDDAI_REPO_OWNER=myusername
TDDAI_REPO_NAME=myproject
```
"""
import os
@@ -15,13 +31,13 @@ class TddaiConfig:
"""Configuration settings for tddai."""
# Workspace settings
workspace_dir: Path = Path(".markitect_workspace")
workspace_dir: Path = Path(".tddai_workspace")
current_issue_file: str = "current_issue.json"
# Git repository settings
gitea_url: str = "http://92.205.130.254:32166"
repo_owner: str = "coulomb"
repo_name: str = "markitect_project"
# Git repository settings (must be configured per project)
gitea_url: str = ""
repo_owner: str = ""
repo_name: str = ""
# Test settings
tests_dir: Path = Path("tests")

View File

@@ -1,5 +1,5 @@
"""
Test coverage analyzer for MarkiTect issues.
Test coverage analyzer for issues.
This module analyzes issues and existing tests to identify gaps in functional test coverage.
"""