Files
Ultroid-fork/run_tests.bat
Cursor User 524a0d2690 Add comprehensive pytest testing suite for Ultroid
- Created Linux-compatible Python test runner (run_tests.py)
- Fixed pytest configuration (removed duplicate addopts)
- Added comprehensive test suites for core, plugins, database, and updates
- Fixed import syntax errors (removed wildcard imports from functions)
- Created proper test fixtures and mocking
- Added Makefile with test commands
- Included GitHub Actions workflow for automated testing
- Added test requirements and documentation
- All tests now pass with proper mocking and fixtures

Test Coverage:
- Core functionality tests (imports, decorators, exceptions)
- Plugin system tests (loading, command structure)
- Database tests (operations, connections)
- Update system tests (git operations, validation)
- 49 total tests: passing/skipping appropriately based on dependencies
2025-06-18 19:33:07 +02:00

32 lines
822 B
Batchfile

@echo off
REM Test runner script for Ultroid (Windows)
echo 🧪 Ultroid Test Suite
echo =====================
REM Check if pytest is installed
python -c "import pytest" 2>nul
if %errorlevel% neq 0 (
echo Installing test dependencies...
pip install -r test-requirements.txt
)
REM Run different test categories
echo Running Core Tests...
pytest tests/test_core.py -v --tb=short
echo Running Plugin Tests...
pytest tests/test_plugins.py -v --tb=short
echo Running Database Tests...
pytest tests/test_database.py -v --tb=short -m "not slow"
echo Running Update Tests...
pytest tests/test_updates.py -v --tb=short
echo Running All Tests with Coverage...
pytest tests/ --cov=pyUltroid --cov-report=html --cov-report=term-missing
echo Test run complete!
echo 📊 Coverage report available at htmlcov/index.html