chore: Second cleanup wave - organize root directory
- Archive: 85 agent .txt files → docs/archive/agents/legacy_txt/ - Scripts: Move 110 shell scripts → scripts/ (keep deploy.sh in root) - Models: Move 18 .safetensors → ml/models/checkpoints/training_artifacts/ - Delete: 34 directories (~33GB freed) - target/, coverage_*, test artifacts - Build: Clean 14 build artifacts (.rlib, .o, .pid, binaries) - Tests: Move 14 .rs files → tests/standalone/ - SQL: Move 5 files → sql/ (keep init-db*.sql for Docker) - Wave 153: Archive to docs/archive/historical/wave153/ - Docs: Archive 9 markdown files to wave_d/reports/ and historical/ Total impact: ~34GB freed (both waves), root directory cleaned from 583 to ~40 essential files Directory count reduced from 65 to 31 (52% reduction) All historical data preserved in organized archive structure
This commit is contained in:
61
scripts/validate_ab_testing_tdd.sh
Executable file
61
scripts/validate_ab_testing_tdd.sh
Executable file
@@ -0,0 +1,61 @@
|
||||
#!/bin/bash
|
||||
# Validation Script for A/B Testing Pipeline TDD Implementation
|
||||
# This script validates the TDD implementation by running tests and checking compilation
|
||||
|
||||
set -e
|
||||
|
||||
echo "============================================"
|
||||
echo "A/B Testing Pipeline TDD Validation"
|
||||
echo "============================================"
|
||||
echo ""
|
||||
|
||||
# Colors for output
|
||||
RED='\033[0;31m'
|
||||
GREEN='\033[0;32m'
|
||||
YELLOW='\033[1;33m'
|
||||
NC='\033[0m' # No Color
|
||||
|
||||
echo "Step 1: Check Docker services"
|
||||
echo "--------------------------------------------"
|
||||
docker-compose ps postgres redis
|
||||
echo ""
|
||||
|
||||
echo "Step 2: Run database migrations"
|
||||
echo "--------------------------------------------"
|
||||
cargo sqlx migrate run || {
|
||||
echo -e "${RED}Migration failed. Check migration syntax.${NC}"
|
||||
exit 1
|
||||
}
|
||||
echo -e "${GREEN}Migrations completed successfully${NC}"
|
||||
echo ""
|
||||
|
||||
echo "Step 3: Compile trading_service"
|
||||
echo "--------------------------------------------"
|
||||
cargo check -p trading_service --tests 2>&1 | tail -20
|
||||
echo -e "${GREEN}Compilation check complete${NC}"
|
||||
echo ""
|
||||
|
||||
echo "Step 4: Run A/B testing pipeline tests"
|
||||
echo "--------------------------------------------"
|
||||
echo -e "${YELLOW}Expected: Tests should FAIL (TDD RED phase)${NC}"
|
||||
echo ""
|
||||
|
||||
cargo test -p trading_service --test ab_testing_pipeline_tests --no-fail-fast 2>&1 | tee ab_testing_test_results.log
|
||||
|
||||
echo ""
|
||||
echo "============================================"
|
||||
echo "Validation Complete"
|
||||
echo "============================================"
|
||||
echo ""
|
||||
echo "Test Results Summary:"
|
||||
echo "--------------------------------------------"
|
||||
grep -E "(test result:|running)" ab_testing_test_results.log | tail -5
|
||||
echo ""
|
||||
echo "Full test output saved to: ab_testing_test_results.log"
|
||||
echo ""
|
||||
echo "Next Steps (TDD Cycle):"
|
||||
echo "1. Review test failures (expected in RED phase)"
|
||||
echo "2. Fix compilation errors if any"
|
||||
echo "3. Fix implementation to make tests pass (GREEN phase)"
|
||||
echo "4. Refactor and optimize (REFACTOR phase)"
|
||||
echo "5. Integrate with ensemble coordinator"
|
||||
Reference in New Issue
Block a user