Skip to main content

cirron test

Run comprehensive tests for ML projects: environment validation, model testing, data pipeline verification, inference, deployed endpoint checks, and end-to-end pipelines.

Usage

Options

When no specific test flags are passed, the default suite runs --env, --requirements, --unit, --model, and --data.

Test Types

Framework-specific behavior is applied automatically based on framework in cirron.yaml:
  • PyTorch: torch.cuda.is_available() when GPU is required, forward pass with dummy data, model structure and methods.
  • TensorFlow: GPU device availability, prediction with dummy data, model interface.
  • Scikit-Learn: presence of fit / predict, model interface.

Examples

Configuration

The CLI detects tests from your project structure (src/model.py with create_model(), src/data_loader.py, src/inference.py with ModelInference, tests/, requirements.txt, Dockerfile) and from cirron.yaml:
Validation data path resolution: -p flag → cirron.yaml config → common paths (data/validation/, data/val/, data/test/, data/sample/). Honors .cirronignore. If no trained model exists, the inference test will automatically train via train.py (Trainer class) and save to models/model.joblib.

Test Output

Tests run sequentially with per-test error handling. Failures don’t stop the suite.

Watch Mode

--watch watches src/**/*.py, tests/**/*.py, and cirron.yaml, automatically re-running unit, model, data, and lint tests on change.

Test Dependencies

Auto-detected: pytest (preferred) or unittest, flake8 (preferred) or pylint, Docker, pip, requests, pandas.

Troubleshooting

CI/CD