Skip to content

Commit 8a63d76

Browse files
committed
Debug failing swift-testing test
1 parent 737bb7c commit 8a63d76

File tree

2 files changed

+21
-1
lines changed

2 files changed

+21
-1
lines changed

src/TestExplorer/TestParsers/SwiftTestingOutputParser.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,10 @@ export class SwiftTestingOutputParser {
182182
public testRunStarted: () => void,
183183
public addParameterizedTestCase: (testClass: TestClass, parentIndex: number) => void,
184184
public onAttachment: (testIndex: number, path: string) => void
185-
) {}
185+
) {
186+
// eslint-disable-next-line no-console
187+
console.log(">>> Swift Testing Output Parser created...");
188+
}
186189

187190
/**
188191
* Watches for test events on the named pipe at the supplied path.
@@ -193,6 +196,8 @@ export class SwiftTestingOutputParser {
193196
runState: ITestRunState,
194197
pipeReader?: INamedPipeReader
195198
): Promise<void> {
199+
// eslint-disable-next-line no-console
200+
console.log(">>> Swift Testing Output Parser watching:", path);
196201
this.path = path;
197202

198203
// Creates a reader based on the platform unless being provided in a test context.
@@ -347,6 +352,8 @@ export class SwiftTestingOutputParser {
347352
}
348353

349354
private parse(item: SwiftTestEvent, runState: ITestRunState) {
355+
// eslint-disable-next-line no-console
356+
console.log(">>> Swift Testing Event:", JSON.stringify(item, null, 2));
350357
if (
351358
item.kind === "test" &&
352359
item.payload.kind === "function" &&

src/debugger/debugAdapterFactory.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,10 @@ export class LLDBDebugConfigurationProvider implements vscode.DebugConfiguration
156156

157157
private async promptForCodeLldbSettings(): Promise<void> {
158158
const libLldbPathResult = await getLLDBLibPath(this.toolchain);
159+
/* eslint-disable no-console */
160+
console.log(">>> libLldbPathResult", libLldbPathResult);
161+
console.log(">>> libLldbPathResult success", libLldbPathResult.success);
162+
console.log(">>> libLldbPathResult failure", libLldbPathResult.failure);
159163
if (!libLldbPathResult.success) {
160164
const errorMessage = `Error: ${getErrorDescription(libLldbPathResult.failure)}`;
161165
vscode.window.showWarningMessage(
@@ -166,6 +170,15 @@ export class LLDBDebugConfigurationProvider implements vscode.DebugConfiguration
166170
}
167171
const libLldbPath = libLldbPathResult.success;
168172
const lldbConfig = vscode.workspace.getConfiguration("lldb");
173+
console.log(">>> lldbConfig library", lldbConfig.get<string>("library"));
174+
console.log(
175+
">>> lldbConfig launch.expressions",
176+
lldbConfig.get<string>("launch.expressions")
177+
);
178+
179+
const allSettings = vscode.workspace.getConfiguration();
180+
console.log(">>> All VS Code settings:", JSON.stringify(allSettings));
181+
169182
if (
170183
lldbConfig.get<string>("library") === libLldbPath &&
171184
lldbConfig.get<string>("launch.expressions") === "native"

0 commit comments

Comments
 (0)