pare-test

v0.24.2
io.github.Dave-London/pare-test Checked 2 hours ago Published 3 days ago

Pare Test ג€” Auto-detects test framework (pytest, jest, vitest, mocha), returns typed JSON.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

run Run Tests

Auto-detects test framework (pytest/jest/vitest/mocha), runs tests, returns structured results with failures.

ParameterTypeDescription
argsarrayAdditional arguments to pass to the test runner. Each element is validated to prevent flag injection.
bailFail fast after N failures (maps to --maxfail=N for pytest, --bail=N for jest/vitest, --bail for mocha). Pass true for 1.
compactbooleanPrefer compact output
configstringPath to test config file (--config for all frameworks)
coveragebooleanRun with coverage (adds --coverage for vitest/jest, --cov for pytest)
exitFirstbooleanStop on first test failure (maps to -x for pytest, --bail=1 for jest/vitest, -b for mocha)
filterstringTest filter pattern (file path or test name pattern)
frameworkstringForce a specific framework instead of auto-detecting
interpreterstringPython interpreter path to use for pytest (overrides venv/PATH detection)
onlyChangedbooleanRun only tests affected by recent changes (maps to --lf for pytest, --onlyChanged for jest, --changed for vitest)
passWithNoTestsbooleanExit successfully when no tests are found (maps to --passWithNoTests for jest/vitest)
pathstringProject root path
shardstringShard spec for distributed test execution (e.g., "1/3") via --shard (jest/vitest)
testNamePatternstringFilter tests by name pattern (maps to -k for pytest, --testNamePattern for jest/vitest, --grep for mocha)
timeoutintegerPer-test timeout in milliseconds (maps to --timeout for pytest-timeout, --testTimeout for jest/vitest, --timeout for mocha)
updateSnapshotsbooleanUpdate snapshots (vitest/jest only, adds -u flag)
workersintegerNumber of parallel workers (maps to -n for pytest-xdist, --maxWorkers for jest, --pool.threads.maxThreads for vitest, --jobs for mocha)

coverage Test Coverage

Runs tests with coverage and returns structured coverage summary per file.

ParameterTypeDescription
allbooleanInclude all source files in coverage, even untested ones (maps to --coverage.all for vitest, --all for nyc)
argsarrayAdditional arguments to pass to the coverage runner. Each element is validated to prevent flag injection.
branchbooleanCollect branch coverage (maps to --cov-branch for pytest)
compactbooleanPrefer compact output
excludearrayFile patterns to exclude from coverage
failUndernumberMinimum line coverage percentage; fail if below (maps to --cov-fail-under for pytest, --coverageThreshold for jest, --coverage.thresholds.lines for vitest, --check-coverage --lines for nyc)
filterstringTest filter pattern to run coverage on a subset of tests
frameworkstringForce a specific framework instead of auto-detecting
interpreterstringPython interpreter path to use for pytest (overrides venv/PATH detection)
pathstringProject root path
sourcearraySource paths to scope coverage (maps to --cov=PATH for pytest, --collectCoverageFrom for jest, --coverage.include for vitest, --include for nyc)

playwright Playwright Tests

Runs Playwright tests with JSON reporter and returns structured results with pass/fail status, duration, and error messages.

ParameterTypeDescription
argsarrayAdditional arguments passed verbatim to `playwright test`, flags included (e.g., ["--list"]). Only NUL/newline characters are rejected.
browserstringBrowser to use (e.g., "chromium", "firefox", "webkit") via --browser
compactbooleanPrefer compact output
configstringPath to non-default Playwright config file (--config)
filterstringTest filter pattern (file path or test name grep pattern)
forbidOnlybooleanFail if test.only is found — CI safety check (maps to --forbid-only)
grepstringRegex pattern for matching tests by title (--grep)
headedbooleanRun tests in headed browser mode
lastFailedbooleanRe-run only previously failed tests (maps to --last-failed)
maxFailuresnumberStop after this many test failures (maps to --max-failures)
onlyChangedbooleanRun only tests affected by recent changes (maps to --only-changed)
passWithNoTestsbooleanExit successfully when no tests are found (maps to --pass-with-no-tests)
pathstringProject root path
projectstringPlaywright project name (e.g., 'chromium', 'firefox', 'webkit')
retriesnumberNumber of retries for failed tests (maps to --retries)
shardstringShard spec for distributed E2E test execution (e.g., "1/3") via --shard
timeoutnumberPer-test timeout in milliseconds (maps to --timeout)
tracestringTrace recording mode (--trace)
updateSnapshotsbooleanUpdate snapshots (adds --update-snapshots flag)
workersnumberNumber of parallel workers for test execution (maps to --workers)