Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/scenarios/server/tools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,11 @@ export class ToolsListScenario implements ClientScenario {
const errors: string[] = [];
if (!result.tools) {
errors.push('Missing tools array');
} else if (!Array.isArray(result.tools)) {
errors.push('tools is not an array');
} else if (result.tools.length === 0) {
errors.push('tools array is empty');
} else {
if (!Array.isArray(result.tools)) {
errors.push('tools is not an array');
}

result.tools.forEach((tool, index) => {
if (!tool.name) errors.push(`Tool ${index}: missing name`);
if (!tool.description)
Expand Down