Merge from vscode a348d103d1256a06a2c9b3f9b406298a9fef6898 (#15681)

* Merge from vscode a348d103d1256a06a2c9b3f9b406298a9fef6898

* Fixes and cleanup

* Distro

* Fix hygiene yarn

* delete no yarn lock changes file

* Fix hygiene

* Fix layer check

* Fix CI

* Skip lib checks

* Remove tests deleted in vs code

* Fix tests

* Distro

* Fix tests and add removed extension point

* Skip failing notebook tests for now

* Disable broken tests and cleanup build folder

* Update yarn.lock and fix smoke tests

* Bump sqlite

* fix contributed actions and file spacing

* Fix user data path

* Update yarn.locks

Co-authored-by: ADS Merger <karlb@microsoft.com>
This commit is contained in:
Charles Gagnon
2021-06-17 08:17:11 -07:00
committed by GitHub
parent fdcb97c7f7
commit 3cb2f552a6
2582 changed files with 124827 additions and 87099 deletions

View File

@@ -20,7 +20,7 @@ export class CopyInsightDialogSelectionAction extends Action {
super(id, label);
}
public async run(event?: IInsightDialogActionContext): Promise<void> {
public override async run(event?: IInsightDialogActionContext): Promise<void> {
await this._clipboardService.writeText(event.cellData);
}
}

View File

@@ -91,14 +91,14 @@ class InsightTableView extends ViewPane {
super(options, keybindingService, contextMenuService, configurationService, contextKeyService, viewDescriptorService, instantiationService, openerService, themeService, telemetryService);
}
protected renderBody(container: HTMLElement): void {
protected override renderBody(container: HTMLElement): void {
this._table = new Table(container, {
columns: this.columns,
dataProvider: this.data
}, this.tableOptions);
}
protected layoutBody(size: number): void {
protected override layoutBody(size: number): void {
this._table.layout(size, Orientation.VERTICAL);
}
@@ -336,7 +336,7 @@ export class InsightsDialogView extends Modal {
});
}
public render() {
public override render() {
super.render();
this._closeButton = this.addFooterButton('Close', () => this.close());
this._register(attachButtonStyler(this._closeButton, this._themeService));
@@ -420,7 +420,7 @@ export class InsightsDialogView extends Modal {
this._taskButtonDisposables = [];
}
protected onClose(e: StandardKeyboardEvent) {
protected override onClose(e: StandardKeyboardEvent) {
this.close();
}

View File

@@ -35,9 +35,10 @@ export async function resolveQueryFilePath(services: ServicesAccessor, filePath?
// Resolve the path using each folder in our workspace, or undefined if there aren't any
// (so that non-folder vars such as environment vars still resolve)
const isRemote = fileService.canHandleResource(URI.from({ scheme: Schemas.vscodeRemote }));
let resolvedFileUris = (workspaceFolders.length > 0 ? workspaceFolders : [undefined])
.map(f => {
const uri = URI.file(configurationResolverService.resolve(f, filePath));
let resolvedFileUriPromises = (workspaceFolders.length > 0 ? workspaceFolders : [undefined])
.map(async f => {
const resolvedUri = await configurationResolverService.resolveAsync(f, filePath);
const uri = URI.file(resolvedUri);
if (f) {
return uri.with({ scheme: f.uri.scheme }); // ensure we maintain the correct scheme
} else if (isRemote) {
@@ -46,6 +47,7 @@ export async function resolveQueryFilePath(services: ServicesAccessor, filePath?
return uri;
}
});
const resolvedFileUris = await Promise.all(resolvedFileUriPromises);
// Just need a single query file so use the first we find that exists
for (const uri of resolvedFileUris) {
@@ -54,5 +56,5 @@ export async function resolveQueryFilePath(services: ServicesAccessor, filePath?
}
}
throw Error(localize('insightsDidNotFindResolvedFile', "Could not find query file at any of the following paths :\n {0}", resolvedFileUris.join('\n')));
throw Error(localize('insightsDidNotFindResolvedFile', "Could not find query file at any of the following paths :\n {0}", resolvedFileUriPromises.join('\n')));
}

View File

@@ -22,7 +22,7 @@ import { IFileService } from 'vs/platform/files/common/files';
import * as pfs from 'vs/base/node/pfs';
import { getRandomTestPath } from 'vs/base/test/node/testUtils';
import { IProcessEnvironment } from 'vs/base/common/platform';
import { NativeWorkbenchEnvironmentService } from 'vs/workbench/services/environment/electron-browser/environmentService';
import { NativeWorkbenchEnvironmentService } from 'vs/workbench/services/environment/electron-sandbox/environmentService';
import { isEqual } from 'vs/base/common/resources';
import { TestWorkbenchConfiguration } from 'vs/workbench/test/electron-browser/workbenchTestServices';
@@ -56,7 +56,6 @@ suite('Insights Utils tests', function () {
test('resolveQueryFilePath resolves path correctly with fully qualified path', async () => {
const configurationResolverService = new ConfigurationResolverService(
undefined,
new MockWorkbenchEnvironmentService({}),
undefined,
undefined,
new TestContextService(),
@@ -64,7 +63,7 @@ suite('Insights Utils tests', function () {
undefined);
const fileService = new class extends TestFileService {
exists(uri: URI): Promise<boolean> {
override exists(uri: URI): Promise<boolean> {
return pfs.exists(uri.fsPath);
}
};
@@ -89,7 +88,6 @@ suite('Insights Utils tests', function () {
));
const configurationResolverService = new ConfigurationResolverService(
undefined,
new MockWorkbenchEnvironmentService({}),
undefined,
undefined,
contextService,
@@ -97,7 +95,7 @@ suite('Insights Utils tests', function () {
undefined);
const fileService = new class extends TestFileService {
exists(uri: URI): Promise<boolean> {
override exists(uri: URI): Promise<boolean> {
return pfs.exists(uri.fsPath);
}
};
@@ -122,7 +120,6 @@ suite('Insights Utils tests', function () {
);
const configurationResolverService = new ConfigurationResolverService(
undefined,
new MockWorkbenchEnvironmentService({}),
undefined,
undefined,
contextService,
@@ -130,7 +127,7 @@ suite('Insights Utils tests', function () {
undefined);
const fileService = new class extends TestFileService {
exists(uri: URI): Promise<boolean> {
override exists(uri: URI): Promise<boolean> {
return pfs.exists(uri.fsPath);
}
};
@@ -157,7 +154,6 @@ suite('Insights Utils tests', function () {
undefined, undefined, undefined));
const configurationResolverService = new ConfigurationResolverService(
undefined,
new MockWorkbenchEnvironmentService({}),
undefined,
undefined,
contextService,
@@ -165,7 +161,7 @@ suite('Insights Utils tests', function () {
undefined);
const fileService = new class extends TestFileService {
exists(uri: URI): Promise<boolean> {
override exists(uri: URI): Promise<boolean> {
return pfs.exists(uri.fsPath);
}
};
@@ -191,7 +187,7 @@ suite('Insights Utils tests', function () {
const environmentService = new MockWorkbenchEnvironmentService({ TEST_PATH: queryFileDir });
// Create mock window service with env variable containing test folder for resolution
const configurationResolverService = new TestConfigurationResolverService({ getExecPath: () => undefined }, environmentService.userEnv,
const configurationResolverService = new TestConfigurationResolverService({ getAppRoot: () => undefined, getExecPath: () => undefined }, Promise.resolve(environmentService.userEnv),
undefined,
undefined,
undefined,
@@ -200,7 +196,7 @@ suite('Insights Utils tests', function () {
undefined);
const fileService = new class extends TestFileService {
exists(uri: URI): Promise<boolean> {
override exists(uri: URI): Promise<boolean> {
return pfs.exists(uri.fsPath);
}
};
@@ -221,7 +217,7 @@ suite('Insights Utils tests', function () {
const environmentService = new MockWorkbenchEnvironmentService({ TEST_PATH: queryFileDir });
// Create mock window service with env variable containing test folder for resolution
const configurationResolverService = new TestConfigurationResolverService({ getExecPath: () => undefined }, environmentService.userEnv,
const configurationResolverService = new TestConfigurationResolverService({ getAppRoot: () => undefined, getExecPath: () => undefined }, Promise.resolve(environmentService.userEnv),
undefined,
undefined,
undefined,
@@ -230,7 +226,7 @@ suite('Insights Utils tests', function () {
undefined);
const fileService = new class extends TestFileService {
exists(uri: URI): Promise<boolean> {
override exists(uri: URI): Promise<boolean> {
return pfs.exists(uri.fsPath);
}
};
@@ -248,7 +244,6 @@ suite('Insights Utils tests', function () {
const invalidPath = path.join('${INVALID}', 'test.sql');
const configurationResolverService = new ConfigurationResolverService(
undefined,
new MockWorkbenchEnvironmentService({}),
undefined,
undefined,
undefined,
@@ -256,7 +251,7 @@ suite('Insights Utils tests', function () {
undefined);
const fileService = new class extends TestFileService {
exists(uri: URI): Promise<boolean> {
override exists(uri: URI): Promise<boolean> {
return pfs.exists(uri.fsPath);
}
};