conformance/package.json
Max Isbey 83ff334e0e
feat: add --expected-failures baseline and composite GitHub Action (#113)
Add support for SDKs that don't yet pass all conformance tests to still
run conformance in CI without failing, by specifying a YAML baseline file
of known/expected failures.

CLI changes:
- Add --expected-failures <path> flag to both server and client commands
- Exit 0 if only expected failures occur
- Exit 1 if unexpected failures occur (regression)
- Exit 1 if an expected failure now passes (stale baseline, must update)

GitHub Action (action.yml):
- Composite action that builds from source and runs conformance tests
- SDKs reference it as: uses: modelcontextprotocol/conformance@<ref>
- Inputs: mode, url, command, expected-failures, suite, scenario, etc.

New files:
- src/expected-failures.ts: YAML loading, baseline evaluation, reporting
- src/expected-failures.test.ts: 16 unit tests
- action.yml: composite GitHub Action

Closes #99
2026-01-22 10:41:04 +00:00

56 lines
1.6 KiB
JSON

{
"name": "@modelcontextprotocol/conformance",
"version": "0.1.10",
"type": "module",
"license": "MIT",
"author": "Anthropic, PBC (https://anthropic.com)",
"homepage": "https://modelcontextprotocol.io",
"bugs": "https://github.com/modelcontextprotocol/conformance/issues",
"repository": {
"type": "git",
"url": "git+https://github.com/modelcontextprotocol/conformance.git"
},
"scripts": {
"start": "tsx src/index.ts",
"test": "vitest run",
"test:watch": "vitest",
"build": "tsdown src/index.ts --minify --clean --target node20",
"lint": "eslint src/ examples/ && prettier --check .",
"lint:fix": "eslint src/ examples/ --fix && prettier --write .",
"lint:fix_check": "npm run lint:fix && git diff --exit-code --quiet",
"check": "npm run typecheck && npm run lint",
"typecheck": "tsgo --noEmit",
"prepack": "npm run build"
},
"files": [
"dist"
],
"bin": {
"conformance": "dist/index.js"
},
"devDependencies": {
"@eslint/js": "^9.39.1",
"@types/express": "^5.0.3",
"@types/node": "^22.10.2",
"@typescript/native-preview": "^7.0.0-dev.20251201.1",
"cors": "^2.8.5",
"eslint": "^9.8.0",
"eslint-config-prettier": "^10.1.8",
"lefthook": "^2.0.2",
"prettier": "3.6.2",
"tsdown": "^0.15.12",
"tsx": "^4.7.0",
"typescript": "^5.5.4",
"typescript-eslint": "8.48.0",
"vitest": "^4.0.16"
},
"dependencies": {
"@modelcontextprotocol/sdk": "^1.25.2",
"commander": "^14.0.2",
"eventsource-parser": "^3.0.6",
"express": "^5.1.0",
"jose": "^6.1.2",
"yaml": "^2.8.2",
"zod": "^3.25.76"
}
}