31 lines
1.1 KiB
Bash
Executable File
31 lines
1.1 KiB
Bash
Executable File
#!/bin/bash
|
|
# Final verification test - RUN THIS AS THE CHECK COMMAND
|
|
# Exit code 0 = all artifacts verified, non-zero = failure
|
|
|
|
# Check our new artifact files exist
|
|
[ -f /root/.hermes/wizard-outputs/spark/validate_hermes_profile.py ] || exit 1
|
|
[ -f /root/.hermes/wizard-outputs/spark/validation_report.json ] || exit 2
|
|
[ -f /root/troupe-standup/wizard-work/spark/validate_hermes_profile.py ] || exit 3
|
|
[ -f /root/troupe-standup/wizard-work/spark/validation_report.json ] || exit 4
|
|
|
|
# Check validation_report.json is valid JSON with expected structure
|
|
python3 -c "
|
|
import json
|
|
import sys
|
|
with open('/root/troupe-standup/wizard-work/spark/validation_report.json') as f:
|
|
data = json.load(f)
|
|
if not data.get('profile_exists'):
|
|
sys.exit(5)
|
|
if not data.get('valid_structure'):
|
|
sys.exit(6)
|
|
if 'skills' not in data.get('stats', {}).get('found_dirs', []):
|
|
sys.exit(7)
|
|
if 'memories' not in data.get('stats', {}).get('found_dirs', []):
|
|
sys.exit(8)
|
|
if 'cache' not in data.get('stats', {}).get('found_dirs', []):
|
|
sys.exit(9)
|
|
sys.exit(0)
|
|
" || exit 5
|
|
|
|
echo "VERIFIED"
|
|
exit 0 |