Automated testing and monitoring suite for MindsDB database integrations
This repository provides automated testing and continuous monitoring for MindsDB's database handlers. It ensures that MindsDB can reliably connect to and query various database systems including PostgreSQL, Oracle, and MS SQL Server.
- Quality Assurance: Catch integration issues before they reach production
- Continuous Monitoring: Automated tests run on every change via GitHub Actions
- Documentation: Each handler includes comprehensive examples and test queries
- Regression Prevention: Ensure new changes don't break existing functionality
- Performance Tracking: Monitor query execution times and identify bottlenecks
| Database | Status | Tests | Documentation |
|---|---|---|---|
| PostgreSQL | 41 tests | 📝 Docs | |
| Oracle XE | 27 tests | 📝 Docs | |
| MS SQL Server | 31 tests | 📝 Docs | |
| Elasticsearch | 48 tests | 📝 Docs |
Each database handler includes tests for:
- ✅ Basic connectivity and authentication
- ✅ Table listing and schema introspection
- ✅ Simple and complex SQL queries
- ✅ JOINs across multiple tables
- ✅ Aggregations and GROUP BY operations
- ✅ Database-specific functions (date, string, numeric)
- ✅ TPC-H benchmark queries (where applicable)
- ✅ Error handling and edge cases
- Automated Testing: Tests run on every push and pull request
- Multiple Environments: Tests against real database instances in Docker
- Fast Feedback: Results available within minutes
- Coverage Reports: Track test coverage for each handler
Each handler includes Docker Compose setup for:
- Quick local testing without manual database installation
- Consistent test environments
- Easy data reset and reinitialization
# Clone the repository
git clone https://github.com/tino097/mindsdb-handlers-monitor.git
cd mindsdb-handlers-monitor
# Choose a database handler to work with
cd postgresql # or: oracle, mssqlEach database handler follows a consistent structure:
database/
├── sql/
│ ├── init_schema.sql # Database schema
│ └── load_data.sql # Test data
├── tests/
│ ├── conftest.py # Test fixtures
│ ├── test_handler.py # Handler-specific tests
│ └── test_tpch_queries.py # Benchmark queries (optional)
├── scripts/
│ └── setup.sh # Setup automation
├── README.md # Handler documentation
└── requirements.txt # Python dependencies
Contributions are welcome! Here's how you can help:
- Create a new directory:
database_name/ - Add test suite following the structure above
- Create GitHub Actions workflow:
.github/workflows/database_name.yml - Update this README with badge and documentation link
- Fork the repository
- Create a feature branch:
git checkout -b feature/improve-tests - Add or modify tests
- Ensure all tests pass:
pytest tests/ -v - Submit a pull request
- Write clear, descriptive test names
- Include docstrings explaining what each test validates
- Follow existing code style and patterns
- Update documentation when adding features
- Ensure CI passes before submitting PR
- MindsDB Documentation: https://docs.mindsdb.com/
- PostgreSQL Handler: https://docs.mindsdb.com/integrations/data-integrations/postgresql
- Oracle Handler: https://docs.mindsdb.com/integrations/data-integrations/oracle
- MS SQL Handler: https://docs.mindsdb.com/integrations/data-integrations/microsoft-sql-server
- TPC-H Benchmark: http://www.tpc.org/tpch/
This project is licensed under the MIT License - see the LICENSE file for details.
- MindsDB Team - For creating an amazing ML platform
- TPC Organization - For the TPC-H benchmark specification
- Database Vendors - For providing open-source/developer editions
- Issues: GitHub Issues
Made with ❤️ for the MindsDB community
Last updated: 2023-10-05