A powerful Python tool for analyzing VectorCAST test reports, generating comprehensive Excel summaries with directory structures, and providing detailed test metrics analysis for automotive software testing projects.
The VectorCAST Report Analyser automates the process of collecting, analyzing, and organizing VectorCAST test reports from complex directory structures. It provides project managers, test engineers, and quality assurance teams with comprehensive insights into test coverage, execution results, and project metrics.
- Time Efficiency: Reduces manual report collection time from hours to minutes
- Comprehensive Analysis: Processes multiple report types simultaneously
- Professional Output: Generates formatted Excel reports with multiple worksheets
- Project Management: Provides directory tree visualization and file organization
- Scalable: Handles large project structures with thousands of files
- Multi-Report Support: Processes Full Reports, Metrics Reports, Test Case Management Reports, Coverage Reports, and Execution Reports
- Intelligent Pattern Matching: Uses regex patterns to identify VectorCAST report files
- Metadata Extraction: Collects file size, modification dates, and directory structure information
- Duplicate Handling: Automatically removes duplicate entries
- Visual Directory Tree: Generates hierarchical directory structure with file icons
- Path Resolution: Handles both absolute and relative path references
- Permission Handling: Gracefully handles access-restricted directories
- File Classification: Categorizes files by type with appropriate icons
- Multi-Sheet Workbooks: Organizes data across multiple themed worksheets
- Summary Dashboard: Provides overview statistics and key metrics
- Professional Formatting: Applies headers, colors, and auto-sized columns
- Data Visualization: Includes charts and formatted tables
- Command Line Interface: Flexible CLI with multiple configuration options
- Logging System: Comprehensive logging for debugging and audit trails
- Error Handling: Robust exception handling with graceful degradation
- Cross-Platform: Works on Windows, macOS, and Linux systems
- Python 3.9+ (recommended 3.11+)
- Memory: Minimum 512MB RAM (2GB+ for large projects)
- Storage: Varies based on project size and report count
pandas>=1.5.0 # Data manipulation and analysis
openpyxl>=3.0.0 # Excel file operations
pathlib # Path handling (standard library)
re # Regular expressions (standard library)
logging # Logging system (standard library)
argparse # Command line parsing (standard library)git clone https://github.com/suduli/VectorCAST_Report_Analyser.git
cd VectorCAST_Report_Analyser
pip install -r requirements.txtwget https://github.com/suduli/VectorCAST_Report_Analyser/archive/main.zip
unzip main.zip
cd VectorCAST_Report_Analyser-main
pip install pandas openpyxlgit clone https://github.com/suduli/VectorCAST_Report_Analyser.git
cd VectorCAST_Report_Analyser
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
pip install -r requirements.txt# Analyze current directory
python VectorCAST_Report_Analyser.py
# Analyze specific directory
python VectorCAST_Report_Analyser.py -d /path/to/project
# Custom output filename
python VectorCAST_Report_Analyser.py -o custom_analysis.xlsx
# Verbose logging
python VectorCAST_Report_Analyser.py -v# Complete analysis with all options
python VectorCAST_Report_Analyser.py \
--directory "/path/to/vectorcast/project" \
--output "project_analysis_2024.xlsx" \
--verbose| Option | Short | Description | Default |
|---|---|---|---|
--directory |
-d |
Root directory to scan | Current directory |
--output |
-o |
Output Excel filename | vectorcast_analysis.xlsx |
--verbose |
-v |
Enable verbose logging | False |
--help |
-h |
Show help message | - |
The tool generates a comprehensive Excel workbook with the following sheets:
- Report Type Overview: Count and size statistics for each report type
- Total Metrics: Aggregate statistics across all reports
- Latest Activity: Most recent modification dates
- Size Analysis: Total and average file sizes
- Full Reports: Complete test execution reports
- Metrics Reports: Code coverage and quality metrics
- Test Case Reports: Test case management and traceability
- Coverage Reports: Code coverage analysis
- Execution Reports: Test execution results and timing
- Visual Structure: Hierarchical view of project directories
- File Classification: Icons and categorization by file type
- Path Information: Full and relative path references
The analyser automatically detects and processes these VectorCAST report types:
| Report Type | Pattern | Description |
|---|---|---|
| Full Report | *.Full_Report.html |
Complete test execution and coverage |
| Metrics Report | *.Metrics_Report.html |
Code quality and coverage metrics |
| Test Case Report | *.Testcase_Management_Report.html |
Test case traceability and management |
| Coverage Report | *.Coverage_Report.html |
Detailed code coverage analysis |
| Execution Report | *.Execution_Report.html |
Test execution results and timing |
VectorCAST_Project/
โโโ ๐ Module1/
โ โโโ ๐ Module1.Full_Report.html
โ โโโ ๐ Module1.Metrics_Report.html
โ โโโ ๐ Module1.Testcase_Management_Report.html
โโโ ๐ Module2/
โ โโโ ๐ Module2.Full_Report.html
โ โโโ ๐ Module2.Coverage_Report.html
โ โโโ ๐ Module2.Execution_Report.html
โโโ ๐ Integration/
โ โโโ ๐ Integration.Full_Report.html
โโโ ๐ vectorcast_analysis.xlsx (Generated Output)
You can modify the report patterns in the code to match your specific naming conventions:
self.report_patterns = {
'full_report': r'.*\.Full_Report\.html$',
'metrics_report': r'.*\.Metrics_Report\.html$',
'testcase_report': r'.*\.Testcase_Management_Report\.html$',
'coverage_report': r'.*\.Coverage_Report\.html$',
'execution_report': r'.*\.Execution_Report\.html$'
}Adjust logging levels for different use cases:
# For development/debugging
logging.getLogger().setLevel(logging.DEBUG)
# For production use
logging.getLogger().setLevel(logging.INFO)
# For quiet operation
logging.getLogger().setLevel(logging.WARNING)VectorCASTReportAnalyser(root_directory: str = ".")| Method | Description | Returns |
|---|---|---|
generate_directory_tree() |
Creates directory tree structure | List[str] |
scan_directory_for_reports() |
Scans for VectorCAST reports | Dict[str, List[Dict]] |
create_excel_report() |
Generates Excel analysis report | None |
extract_file_names() |
Extracts files matching patterns | List[str] |
# Run all tests
python -m pytest tests/
# Run with coverage
python -m pytest tests/ --cov=VectorCAST_Report_Analyser
# Run specific test
python -m pytest tests/test_report_extraction.py# Test with sample data
python VectorCAST_Report_Analyser.py -d tests/sample_data -vError: Permission denied accessing directory
Solution: Run with appropriate permissions or use --directory flag
Error: ModuleNotFoundError: No module named 'pandas'
Solution: pip install pandas openpyxl
Issue: Slow processing on large directories
Solution: Use --verbose flag to monitor progress, consider excluding non-essential directories
Error: Permission denied writing Excel file
Solution: Ensure output file is not open in Excel, check write permissions
Enable debug logging for detailed troubleshooting:
python VectorCAST_Report_Analyser.py -v -d /path/to/projectBased on internal testing:
| Project Size | Files Scanned | Processing Time | Excel Size |
|---|---|---|---|
| Small (< 100 files) | ~50 reports | 5-10 seconds | < 1MB |
| Medium (100-1000 files) | ~200 reports | 30-60 seconds | 1-5MB |
| Large (1000+ files) | ~500+ reports | 2-5 minutes | 5-20MB |
- HTML report generation
- Interactive dashboard
- Report comparison features
- Custom filtering options
- Web-based interface
- Real-time monitoring
- Database integration
- Advanced analytics
- Machine learning insights
- Predictive analytics
- CI/CD integration
- Cloud deployment options
We welcome contributions! Please follow these guidelines:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Write tests for new functionality
- Ensure all tests pass (
python -m pytest) - Update documentation
- Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Create a Pull Request
- Follow PEP 8 style guidelines
- Add type hints for all functions
- Include comprehensive docstrings
- Maintain test coverage above 80%
- Update README for new features
- Automotive: ECU testing and validation
- Aerospace: Safety-critical software testing
- Medical Devices: FDA compliance reporting
- Industrial Automation: Quality assurance
"Reduced our report analysis time from 4 hours to 15 minutes!" - QA Manager, Automotive OEM
"Essential tool for managing large VectorCAST projects." - Test Engineer, Aerospace
This project is licensed under the MIT License - see the LICENSE file for details.
Suduli Kumar
- Role: Senior Test Automation Engineer
- Email: [suduli.office@gmail.com]
- LinkedIn: [linkedin.com/in/suduli-kumar]
- GitHub: @suduli
- Vector Informatik GmbH for VectorCAST testing framework
- Python Community for excellent libraries (pandas, openpyxl)
- Open Source Contributors for inspiration and best practices
- Quality Assurance Teams for feedback and feature requests
- GitHub Issues: Report bugs or request features
- Documentation: Check this README and code comments
- Community: Join discussions in GitHub Discussions
For enterprise support, custom features, or consulting services, please contact:
- Email: [suduli.office@gmail.com]
- LinkedIn: [Professional inquiries welcome[https://www.linkedin.com/in/suduli/]]
โญ If this tool helped you, please star the repository!
๐ Share with your team and contribute to the automotive testing community!
Built with โค๏ธ for test engineers and quality assurance professionals worldwide