Skip to content

Commit 6c8a229

Browse files
data-douserCopilot
andcommitted
Apply suggestions from code review
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Nathan Randall <70299490+data-douser@users.noreply.github.com>
1 parent 4ae4021 commit 6c8a229

File tree

3 files changed

+40
-7
lines changed

3 files changed

+40
-7
lines changed
Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
11
{
2-
"sessions": []
2+
"sessions": [
3+
{
4+
"expectedContentPatterns": [
5+
"does not exist"
6+
]
7+
}
8+
]
39
}

client/src/lib/integration-test-runner.js

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -227,12 +227,32 @@ export class IntegrationTestRunner {
227227
this.logger.log(`Completed ${totalIntegrationTests} tool-specific integration tests`);
228228

229229
// Also run workflow integration tests
230-
await this.runWorkflowIntegrationTests(baseDir);
230+
const workflowIntegrationSucceeded = await this.runWorkflowIntegrationTests(baseDir);
231+
if (!workflowIntegrationSucceeded) {
232+
this.logger.logTest(
233+
"Workflow integration tests",
234+
false,
235+
new Error("Workflow integration tests did not complete successfully")
236+
);
237+
}
231238

232239
// Also run prompt integration tests
233-
await this.runPromptIntegrationTests(baseDir);
240+
const promptIntegrationSucceeded = await this.runPromptIntegrationTests(baseDir);
241+
if (!promptIntegrationSucceeded) {
242+
this.logger.logTest(
243+
"Prompt integration tests",
244+
false,
245+
new Error("Prompt integration tests did not complete successfully")
246+
);
247+
}
234248

235-
return totalIntegrationTests > 0;
249+
return (
250+
(totalIntegrationTests > 0 ||
251+
workflowIntegrationSucceeded ||
252+
promptIntegrationSucceeded) &&
253+
workflowIntegrationSucceeded &&
254+
promptIntegrationSucceeded
255+
);
236256
} catch (error) {
237257
this.logger.log(`Error running integration tests: ${error.message}`, "ERROR");
238258
return false;

server/src/prompts/workflow-prompts.ts

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1031,9 +1031,16 @@ ${workspaceUri ? `- **Workspace URI**: ${workspaceUri}
10311031

10321032
let resolvedWorkspaceUri = workspaceUri;
10331033
if (workspaceUri) {
1034-
const wsResult = resolvePromptFilePath(workspaceUri);
1035-
resolvedWorkspaceUri = wsResult.resolvedPath;
1036-
if (wsResult.warning) warnings.push(wsResult.warning);
1034+
const trimmedWorkspaceUri = workspaceUri.trim();
1035+
// If the workspace value is already a URI (e.g., "file://..."), preserve it as-is.
1036+
// Only run filesystem path resolution for non-URI values.
1037+
if (/^file:\/\//i.test(trimmedWorkspaceUri)) {
1038+
resolvedWorkspaceUri = trimmedWorkspaceUri;
1039+
} else {
1040+
const wsResult = resolvePromptFilePath(workspaceUri);
1041+
resolvedWorkspaceUri = wsResult.resolvedPath;
1042+
if (wsResult.warning) warnings.push(wsResult.warning);
1043+
}
10371044
}
10381045

10391046
let contextSection = '## Your Development Context\n\n';

0 commit comments

Comments
 (0)