Skip to content

Commit f6035cd

Browse files
pcarletonclaude
andcommitted
Add comprehensive auth scenario test suite
- Add index.test.ts to test all auth scenarios with auth-test.ts client - Upgrade @modelcontextprotocol/sdk from 1.20.1 to 1.22.0 - All 5 auth scenarios now pass including auth/basic-metadata-var2 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent 3f50f78 commit f6035cd

File tree

3 files changed

+134
-18
lines changed

3 files changed

+134
-18
lines changed

package-lock.json

Lines changed: 107 additions & 17 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
"vitest": "^4.0.5"
4444
},
4545
"dependencies": {
46-
"@modelcontextprotocol/sdk": "^1.20.1",
46+
"@modelcontextprotocol/sdk": "^1.22.0",
4747
"commander": "^14.0.2",
4848
"express": "^5.1.0",
4949
"lefthook": "^2.0.2",
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
import {
2+
runClientAgainstScenario,
3+
SpawnedClientRunner
4+
} from './test_helpers/testClient.js';
5+
import path from 'path';
6+
import { listScenarios } from '../../index.js';
7+
8+
describe('Client Auth Scenarios', () => {
9+
const clientPath = path.join(
10+
process.cwd(),
11+
'examples/clients/typescript/auth-test.ts'
12+
);
13+
14+
// Get all scenarios that start with 'auth/'
15+
const authScenarios = listScenarios().filter((name) =>
16+
name.startsWith('auth/')
17+
);
18+
19+
// Generate individual test for each auth scenario
20+
for (const scenarioName of authScenarios) {
21+
test(`${scenarioName} passes`, async () => {
22+
const runner = new SpawnedClientRunner(clientPath);
23+
await runClientAgainstScenario(runner, scenarioName);
24+
});
25+
}
26+
});

0 commit comments

Comments
 (0)