feat(swagger): Add Swagger API reference, and fixes #28

Merged
Gandalf merged 28 commits from develop into main 2026-05-21 20:14:36 +01:00
Showing only changes of commit f3e1bd17fb - Show all commits
+13 -5
View File
@@ -271,15 +271,23 @@ describe('Swagger Coverage', () => {
});
it('should have x-integration-notes for critical endpoints', () => {
const paths = openapiSpec.paths;
// Use merged spec if available, otherwise skip this test
if (!swaggerSpec || !swaggerSpec.paths) {
return;
}
const paths = swaggerSpec.paths;
// Check that auth login has integration notes (as a section header)
const loginDesc = paths['/api/auth/login'].post.description || '';
expect(loginDesc).toContain('x-integration-notes:');
if (paths['/api/auth/login'] && paths['/api/auth/login'].post) {
const loginDesc = paths['/api/auth/login'].post.description || '';
expect(loginDesc).toContain('x-integration-notes:');
}
// Check that stream SSE has integration notes (as a section header)
const streamDesc = paths['/api/dashboard/stream'].get.description || '';
expect(streamDesc).toContain('x-integration-notes:');
if (paths['/api/dashboard/stream'] && paths['/api/dashboard/stream'].get) {
const streamDesc = paths['/api/dashboard/stream'].get.description || '';
expect(streamDesc).toContain('x-integration-notes:');
}
});
it('should properly reference security schemes in operations', () => {