Fix Demo enterprise
This commit is contained in:
102
scripts/comprehensive_demo_validation.py
Executable file
102
scripts/comprehensive_demo_validation.py
Executable file
@@ -0,0 +1,102 @@
|
||||
#!/usr/bin/env python3
|
||||
"""
|
||||
Comprehensive Demo Validation Script
|
||||
|
||||
Runs all validation checks for enterprise demo fixtures and provides a complete report.
|
||||
"""
|
||||
|
||||
import subprocess
|
||||
import sys
|
||||
import os
|
||||
|
||||
def run_validation():
|
||||
"""Run the enterprise demo fixtures validation"""
|
||||
print("=== Running Enterprise Demo Fixtures Validation ===")
|
||||
print()
|
||||
|
||||
try:
|
||||
# Run the main validation script
|
||||
result = subprocess.run([
|
||||
sys.executable,
|
||||
"scripts/validate_enterprise_demo_fixtures.py"
|
||||
], capture_output=True, text=True, cwd=".")
|
||||
|
||||
print(result.stdout)
|
||||
|
||||
if result.returncode != 0:
|
||||
print("❌ Validation failed!")
|
||||
print("Error output:")
|
||||
print(result.stderr)
|
||||
return False
|
||||
else:
|
||||
print("✅ Validation passed!")
|
||||
return True
|
||||
|
||||
except Exception as e:
|
||||
print(f"❌ Error running validation: {e}")
|
||||
return False
|
||||
|
||||
def run_summary():
|
||||
"""Run the demo fixtures summary"""
|
||||
print("\n=== Running Demo Fixtures Summary ===")
|
||||
print()
|
||||
|
||||
try:
|
||||
# Run the summary script
|
||||
result = subprocess.run([
|
||||
sys.executable,
|
||||
"scripts/demo_fixtures_summary.py"
|
||||
], capture_output=True, text=True, cwd=".")
|
||||
|
||||
print(result.stdout)
|
||||
|
||||
if result.returncode != 0:
|
||||
print("❌ Summary failed!")
|
||||
print("Error output:")
|
||||
print(result.stderr)
|
||||
return False
|
||||
else:
|
||||
print("✅ Summary completed!")
|
||||
return True
|
||||
|
||||
except Exception as e:
|
||||
print(f"❌ Error running summary: {e}")
|
||||
return False
|
||||
|
||||
def main():
|
||||
"""Main function to run comprehensive validation"""
|
||||
print("🚀 Starting Comprehensive Demo Validation")
|
||||
print("=" * 60)
|
||||
|
||||
# Change to project directory
|
||||
os.chdir("/Users/urtzialfaro/Documents/bakery-ia")
|
||||
|
||||
# Run validation
|
||||
validation_passed = run_validation()
|
||||
|
||||
# Run summary
|
||||
summary_passed = run_summary()
|
||||
|
||||
# Final report
|
||||
print("\n" + "=" * 60)
|
||||
print("📋 FINAL REPORT")
|
||||
print("=" * 60)
|
||||
|
||||
if validation_passed and summary_passed:
|
||||
print("🎉 ALL CHECKS PASSED!")
|
||||
print("✅ Enterprise demo fixtures are ready for use")
|
||||
print("✅ All cross-references are valid")
|
||||
print("✅ No missing IDs or broken relationships")
|
||||
print("✅ All required files are present")
|
||||
return True
|
||||
else:
|
||||
print("❌ VALIDATION FAILED!")
|
||||
if not validation_passed:
|
||||
print("❌ Cross-reference validation failed")
|
||||
if not summary_passed:
|
||||
print("❌ Summary generation failed")
|
||||
return False
|
||||
|
||||
if __name__ == "__main__":
|
||||
success = main()
|
||||
sys.exit(0 if success else 1)
|
||||
Reference in New Issue
Block a user