chore(vscode): update to 1.55.2
This commit is contained in:
@@ -8,9 +8,9 @@ import { join } from 'vs/base/common/path';
|
||||
import { tmpdir } from 'os';
|
||||
import { promises } from 'fs';
|
||||
import { rimraf, writeFile } from 'vs/base/node/pfs';
|
||||
import { getRandomTestPath } from 'vs/base/test/node/testUtils';
|
||||
import { flakySuite, getRandomTestPath } from 'vs/base/test/node/testUtils';
|
||||
|
||||
suite('Crypto', () => {
|
||||
flakySuite('Crypto', () => {
|
||||
|
||||
let testDir: string;
|
||||
|
||||
|
||||
@@ -10,10 +10,9 @@ import { join, sep } from 'vs/base/common/path';
|
||||
import { generateUuid } from 'vs/base/common/uuid';
|
||||
import { copy, exists, move, readdir, readDirsInDir, rimraf, RimRafMode, rimrafSync, SymlinkSupport, writeFile, writeFileSync } from 'vs/base/node/pfs';
|
||||
import { timeout } from 'vs/base/common/async';
|
||||
import { getPathFromAmdModule } from 'vs/base/common/amd';
|
||||
import { canNormalize } from 'vs/base/common/normalization';
|
||||
import { VSBuffer } from 'vs/base/common/buffer';
|
||||
import { flakySuite, getRandomTestPath } from 'vs/base/test/node/testUtils';
|
||||
import { flakySuite, getRandomTestPath, getPathFromAmdModule } from 'vs/base/test/node/testUtils';
|
||||
import { isWindows } from 'vs/base/common/platform';
|
||||
|
||||
flakySuite('PFS', function () {
|
||||
@@ -232,14 +231,19 @@ flakySuite('PFS', function () {
|
||||
assert.ok(!symbolicLink2);
|
||||
}
|
||||
|
||||
// Copy ignores dangling symlinks
|
||||
// Copy does not fail over dangling symlinks
|
||||
|
||||
await rimraf(copyTarget);
|
||||
await rimraf(symbolicLinkTarget);
|
||||
|
||||
await copy(symLink, copyTarget, { preserveSymlinks: true }); // this should not throw
|
||||
|
||||
assert.ok(!fs.existsSync(copyTarget));
|
||||
if (!isWindows) {
|
||||
const { symbolicLink } = await SymlinkSupport.stat(copyTarget);
|
||||
assert.ok(symbolicLink?.dangling);
|
||||
} else {
|
||||
assert.ok(!fs.existsSync(copyTarget));
|
||||
}
|
||||
});
|
||||
|
||||
test('copy handles symbolic links when the reference is inside source', async () => {
|
||||
|
||||
@@ -8,7 +8,7 @@ import * as cp from 'child_process';
|
||||
import * as objects from 'vs/base/common/objects';
|
||||
import * as platform from 'vs/base/common/platform';
|
||||
import * as processes from 'vs/base/node/processes';
|
||||
import { getPathFromAmdModule } from 'vs/base/common/amd';
|
||||
import { getPathFromAmdModule } from 'vs/base/test/node/testUtils';
|
||||
|
||||
function fork(id: string): cp.ChildProcess {
|
||||
const opts: any = {
|
||||
|
||||
@@ -5,12 +5,17 @@
|
||||
|
||||
import type { Suite } from 'mocha';
|
||||
import { join } from 'vs/base/common/path';
|
||||
import { URI } from 'vs/base/common/uri';
|
||||
import { generateUuid } from 'vs/base/common/uuid';
|
||||
|
||||
export function getRandomTestPath(tmpdir: string, ...segments: string[]): string {
|
||||
return join(tmpdir, ...segments, generateUuid());
|
||||
}
|
||||
|
||||
export function getPathFromAmdModule(requirefn: typeof require, relativePath: string): string {
|
||||
return URI.parse(requirefn.toUrl(relativePath)).fsPath;
|
||||
}
|
||||
|
||||
export function flakySuite(title: string, fn: (this: Suite) => void): Suite {
|
||||
return suite(title, function () {
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
import * as assert from 'assert';
|
||||
import { URI } from 'vs/base/common/uri';
|
||||
import { readFileSync } from 'fs';
|
||||
import { getPathFromAmdModule } from 'vs/base/common/amd';
|
||||
import { getPathFromAmdModule } from 'vs/base/test/node/testUtils';
|
||||
|
||||
suite('URI - perf', function () {
|
||||
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import * as assert from 'assert';
|
||||
import { getDefaultUserDataPath } from 'vs/base/node/userDataPath';
|
||||
|
||||
suite('User data path', () => {
|
||||
|
||||
test('getDefaultUserDataPath', () => {
|
||||
const path = getDefaultUserDataPath();
|
||||
assert.ok(path.length > 0);
|
||||
});
|
||||
});
|
||||
@@ -9,9 +9,8 @@ import { tmpdir } from 'os';
|
||||
import { promises } from 'fs';
|
||||
import { extract } from 'vs/base/node/zip';
|
||||
import { rimraf, exists } from 'vs/base/node/pfs';
|
||||
import { getPathFromAmdModule } from 'vs/base/common/amd';
|
||||
import { createCancelablePromise } from 'vs/base/common/async';
|
||||
import { getRandomTestPath } from 'vs/base/test/node/testUtils';
|
||||
import { getRandomTestPath, getPathFromAmdModule } from 'vs/base/test/node/testUtils';
|
||||
|
||||
suite('Zip', () => {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user