Skip to content

Commit 9c5b840

Browse files
committed
fixing unit test for debug-session
1 parent 2601b56 commit 9c5b840

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/debug-session/gdbtarget-debug-session.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ describe('GDBTargetDebugSession', () => {
8181
const logDebugSpy = jest.spyOn(logger, 'debug');
8282
(debugSession.customRequest as jest.Mock).mockRejectedValueOnce(new Error('myError'));
8383
const result = await gdbTargetSession.evaluateGlobalExpression('myGlobalVariable');
84-
expect(result).toBe('Error: could not evaluate expression');
84+
expect(result).toBe('myError');
8585
expect(debugSession.customRequest as jest.Mock).toHaveBeenCalledWith('evaluate', { expression: 'myGlobalVariable', frameId: 0, context: 'hover' });
8686
expect(logDebugSpy).toHaveBeenCalledWith('Session \'session-name\': Failed to evaluate global expression \'myGlobalVariable\' - \'myError\'');
8787
});

0 commit comments

Comments
 (0)