- Deleted obsolete test files: test_mime.go, test_mime_integration.go, and xmpp_client_upload_diagnosis.ipynb. - Updated README.md to reflect the new version 3.3.0 "Nexus Infinitum" and its features. - Added comprehensive release notes for version 3.3.0 detailing major enhancements and installation instructions. - Introduced cleanup script to remove development artifacts while preserving production files.
3.4 KiB
3.4 KiB
HMAC File Server 3.2.2 Test Suite
This directory contains comprehensive testing tools for the HMAC File Server 3.3.0 "Nexus Infinitum".
🚀 Quick Start
Run the complete test suite:
./comprehensive_test_suite.sh
📋 Test Coverage
The comprehensive test suite covers:
✅ Core Functionality
- HMAC Validation: Ensures proper authentication
- File Extensions: Tests allowed/blocked file types
- Upload Mechanics: Validates upload process
- Server Health: Checks service availability
🎥 XMPP Integration
- MP4 Upload: Tests video file sharing for XMPP clients
- Image Upload: Tests image sharing (PNG, JPEG)
- File Size Limits: Validates large file handling
🌐 Network Resilience (3.2.2 Features)
- Health Monitoring: Tests network resilience endpoints
- Metrics Collection: Validates monitoring capabilities
- Mobile Switching: Supports seamless network transitions
🚫 Security Testing
- Invalid HMAC: Ensures rejected authentication fails
- Unsupported Extensions: Confirms blocked file types
- Path Validation: Tests file path sanitization
🔧 Commands
# Run all tests
./comprehensive_test_suite.sh
# Setup test files only
./comprehensive_test_suite.sh setup
# Clean up test files
./comprehensive_test_suite.sh clean
# Show help
./comprehensive_test_suite.sh help
📊 Test Results
Tests generate detailed logs with:
- ✅ Pass/Fail status for each test
- 🕒 Timestamps for performance tracking
- 📝 Detailed output saved to
/tmp/hmac_test_results_*.log
- 📈 Summary statistics (passed/failed counts)
🎯 Expected Results
When all systems are working correctly:
- ✅ PASS: HMAC validation
- ✅ PASS: MP4 upload (XMPP)
- ✅ PASS: Image upload
- ✅ PASS: Large file upload
- ✅ PASS: Server health check
- ❌ FAIL: Invalid HMAC (should fail)
- ❌ FAIL: Unsupported extension (should fail)
🔍 Troubleshooting
Common Issues
- Connection refused: Check if server is running
- 403 Forbidden: Verify HMAC key configuration
- 400 Bad Request: Check file extension configuration
- Timeout: Large files may need adjusted timeouts
Debug Mode
For detailed debugging, check server logs:
sudo journalctl -u hmac-file-server -f
📁 File Cleanup
The test suite automatically cleans up temporary files, but if needed:
rm -f /tmp/test_*.{txt,mp4,bin,png,xyz}
rm -f /tmp/hmac_test_results_*.log
🔧 Configuration
Tests use these defaults (modify in script if needed):
- Base URL:
https://xmpp.uuxo.net
- Test User:
c184288b79f8b7a6f7d87ac7f1fb1ce6dcf49a80
- HMAC Key: Configured in script
📝 Legacy Test Files
This comprehensive suite replaces these scattered root-level test files:
test-hmac-fixed.sh
→ Integrated into comprehensive suitetest-upload.sh
→ Covered by upload testsdebug-uploads.sh
→ Debug logging integratedcomprehensive_upload_test.sh
→ Replaced by this suite- Various monitor scripts → Health checks integrated
🎉 3.3.0 "Nexus Infinitum" Features Tested
- ✅ Enhanced Network Resilience: 1-second detection
- ✅ Mobile Network Switching: WLAN ↔ IPv6 5G seamless transitions
- ✅ XMPP File Sharing: Conversations/Gajim compatibility
- ✅ Configuration Validation: Proper extension loading
- ✅ Production Deployment: SystemD, Docker, Podman support