mix pd.integration (PropertyDamage v0.2.0)
View SourceRun PropertyDamage integration tests against a live service.
This task runs stateful property-based tests against a running service, with support for health checks, reporting, and failure persistence.
Usage
mix pd.integration --model MyModel --adapter MyAdapter --url http://localhost:4000Required Options
--model The model module (e.g., ToyBankTest.Model)
--adapter The adapter module (e.g., ToyBankTest.Adapters.HTTPAdapter)
--url Base URL of the service under testOptional Options
--runs Number of test runs (default: 100)
--commands Max commands per run (default: 50)
--health Health check URL (default: {url}/health or {url}/api/health)
--report Report format: terminal, markdown, junit, json
--report-path Path for report file (required for non-terminal formats)
--save-failures Directory to save failure files
--stop-on-fail Stop on first failure
--hunt Bug hunt mode: stop after finding N unique bugs
--verbose Show detailed progress (default: true)
--quiet Suppress progress outputExamples
# Basic integration test
mix pd.integration \
--model ToyBankTest.Model \
--adapter ToyBankTest.Adapters.HTTPAdapter \
--url http://localhost:4555
# With JUnit report for CI
mix pd.integration \
--model ToyBankTest.Model \
--adapter ToyBankTest.Adapters.HTTPAdapter \
--url http://localhost:4555 \
--runs 500 \
--report junit \
--report-path reports/integration.xml
# Bug hunting mode
mix pd.integration \
--model ToyBankTest.Model \
--adapter ToyBankTest.Adapters.HTTPAdapter \
--url http://localhost:4555 \
--hunt 10 \
--save-failures discovered_bugs/
# Quick smoke test
mix pd.integration \
--model ToyBankTest.Model \
--adapter ToyBankTest.Adapters.HTTPAdapter \
--url http://localhost:4555 \
--runs 10 \
--stop-on-failExit Codes
0 - All tests passed
1 - One or more tests failed
2 - Configuration or setup errorEnvironment Variables
PROPERTYDAMAGE_BASE_URL - Default base URL if --url not provided
PROPERTYDAMAGE_RUNS - Default number of runs