Skip to content

Commit 3fa49bc

Browse files
authored
Set log level to trace when positron-r extension tests are running (#10895)
So we get more detailed logs for both positron-r and kernel-supervisor. Would be helpful to figure out #10121 (comment) Since that only affects the Positron process running positron-r tests, that verbosity setting should not have any negative impact on QA and dev teams. <!-- Thank you for submitting a pull request. If this is your first pull request you can find information about contributing here: * https://github.com/posit-dev/positron/blob/main/CONTRIBUTING.md We recommend synchronizing your branch with the latest changes in the main branch by either pulling or rebasing. --> <!-- Describe briefly what problem this pull request resolves, or what new feature it introduces. Include screenshots of any new or altered UI. Link to any GitHub issues but avoid "magic" keywords that will automatically close the issue. If there are any details about your approach that are unintuitive or you want to draw attention to, please describe them here. --> ### Release Notes <!-- Optionally, replace `N/A` with text to be included in the next release notes. The `N/A` bullets are ignored. If you refer to one or more Positron issues, these issues are used to collect information about the feature or bugfix, such as the relevant language pack as determined by Github labels of type `lang: `. The note will automatically be tagged with the language. These notes are typically filled by the Positron team. If you are an external contributor, you may ignore this section. --> #### New Features - N/A #### Bug Fixes - N/A ### QA Notes <!-- Positron team members: please add relevant e2e test tags, so the tests can be run when you open this pull request. - Instructions: https://github.com/posit-dev/positron/blob/main/test/e2e/README.md#pull-requests-and-test-tags - Available tags: https://github.com/posit-dev/positron/blob/main/test/e2e/infra/test-runner/test-tags.ts --> <!-- Add additional information for QA on how to validate the change, paying special attention to the level of risk, adjacent areas that could be affected by the change, and any important contextual information not present in the linked issues. -->
1 parent 19cefa1 commit 3fa49bc

File tree

4 files changed

+9
-2
lines changed

4 files changed

+9
-2
lines changed

extensions/positron-r/src/lsp.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ export class ArkLsp implements vscode.Disposable {
143143
// With a `.` rather than a `-` so vscode-languageserver can look up related options correctly
144144
const id = 'positron.r';
145145

146-
const message = `Creating ${this._dynState.sessionName} language client for session ${this._metadata.sessionId} on port ${port}`;
146+
const message = `Creating language client ${this._dynState.sessionName} for session ${this._metadata.sessionId} on port ${port}`;
147147

148148
LOGGER.info(message);
149149
outputChannel.appendLine(message);

extensions/positron-r/src/test/ark-comm.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
* Licensed under the Elastic License 2.0. See LICENSE.txt for license information.
44
*--------------------------------------------------------------------------------------------*/
55

6+
import './mocha-setup'
7+
68
import * as assert from 'assert';
79
import * as vscode from 'vscode';
810
import * as testKit from './kit';

extensions/positron-r/src/test/debugger.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
* Licensed under the Elastic License 2.0. See LICENSE.txt for license information.
44
*--------------------------------------------------------------------------------------------*/
55

6+
import './mocha-setup'
7+
68
import * as vscode from 'vscode';
79
import * as assert from 'assert';
810
import * as testKit from './kit';

extensions/positron-r/src/test/mocha-setup.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@ import * as testKit from './kit';
99
export let currentTestName: string | undefined;
1010

1111
suiteSetup(async () => {
12-
// Set Ark log level to TRACE for easier debugging of tests
12+
// Set global Positron log level to trace for easier debugging
13+
await vscode.commands.executeCommand('_extensionTests.setLogLevel', 'trace');
14+
15+
// Set Ark kernel process log level to trace
1316
await vscode.workspace.getConfiguration().update('positron.r.kernel.logLevel', 'trace', vscode.ConfigurationTarget.Global);
1417

1518
// To be safe

0 commit comments

Comments
 (0)