// dispatchers/protocols-dispatcher.ts — GraphQL, gRPC, WebSocket, Hypermedia dispatches
import { isHypermediaProject, generateHypermediaTestDefs, generateHypermediaTestFiles, } from '../generators/hypermedia-generator.js';
import { isGraphqlProject, generateGraphqlTestDefs, generateGraphqlTestFiles, } from '../generators/graphql-test-generator.js';
import { isGrpcProject, generateGrpcTestDefs, generateGrpcTestFiles, } from '../generators/grpc-test-generator.js';
import { isWebSocketProject, generateWebSocketTestDefs, generateWebSocketTestFiles, } from '../generators/websocket-test-generator.js';
export function dispatchProtocols(spec, knowledge, testDir, testFramework, slug, autoGenerate, testExt, _unitTests, integrationTests, testFiles) {
    if (isHypermediaProject(knowledge)) {
        integrationTests.push(...generateHypermediaTestDefs(spec.title, testDir));
        testFiles.push(...generateHypermediaTestFiles(spec, testDir, knowledge.language, autoGenerate));
    }
    if (isGraphqlProject(knowledge)) {
        const gqlDefs = generateGraphqlTestDefs(spec.title, testDir, testExt);
        integrationTests.push(...gqlDefs);
        testFiles.push(...generateGraphqlTestFiles({ title: spec.title, slug }, testDir, testFramework, knowledge.language, testExt, autoGenerate));
    }
    if (isGrpcProject(knowledge)) {
        const grpcDefs = generateGrpcTestDefs(spec.title, testDir, testExt);
        integrationTests.push(...grpcDefs);
        testFiles.push(...generateGrpcTestFiles({ title: spec.title, slug }, testDir, testFramework, knowledge.language, testExt, autoGenerate));
    }
    if (isWebSocketProject(knowledge)) {
        const wsDefs = generateWebSocketTestDefs(spec.title, testDir, testExt);
        integrationTests.push(...wsDefs);
        testFiles.push(...generateWebSocketTestFiles({ title: spec.title, slug }, testDir, testFramework, knowledge.language, testExt, autoGenerate));
    }
}
//# sourceMappingURL=protocols-dispatcher.js.map