Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vscode ver > 1.38 #188

Merged
merged 1 commit into from
May 4, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ platform:

environment:
C2_DEBUG: true
nodejs_version: "10"
nodejs_version: '10'

matrix:
- VSCODE_VERSION: "latest"
#- VSCODE_VERSION: "1.31.0" appveyor is too slow and we have similar tests using travis
- VSCODE_VERSION: 'latest'
#- VSCODE_VERSION: "1.38.0" appveyor is too slow and we have similar tests using travis

install:
- ps: Install-Product node $env:nodejs_version
Expand Down
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,10 @@ jobs:
env: VSCODE_VERSION=latest

- os: linux
env: VSCODE_VERSION=1.31.0
env: VSCODE_VERSION=1.38.0
if: branch = master
- os: osx
env: VSCODE_VERSION=1.31.0
env: VSCODE_VERSION=1.38.0
if: branch = master

- os: linux
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@
"webpack-cli": "^3.3.11"
},
"engines": {
"vscode": "^1.23.0"
"vscode": "^1.38.0"
},
"activationEvents": [
"onView:test-explorer",
Expand Down
48 changes: 29 additions & 19 deletions src/Configurations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -132,27 +132,37 @@ export class Configurations {
// NOTE: update is async operation
// This is not the nicest solution but should work and simple.

this._new
.update(newName, oldVals.globalValue, vscode.ConfigurationTarget.Global)
.then(undefined, e => this._log.exceptionS(e));
this._new
.update(newName, oldVals.workspaceValue, vscode.ConfigurationTarget.Workspace)
.then(undefined, e => this._log.exceptionS(e));
this._new
.update(newName, oldVals.workspaceFolderValue, vscode.ConfigurationTarget.WorkspaceFolder)
.then(undefined, e => this._log.exceptionS(e));

const oldVal = this._old.get<T>(oldName);

this._old
.update(oldName, undefined, vscode.ConfigurationTarget.Global)
.then(undefined, e => this._log.exceptionS(e));
this._old
.update(oldName, undefined, vscode.ConfigurationTarget.Workspace)
.then(undefined, e => this._log.exceptionS(e));
this._old
.update(oldName, undefined, vscode.ConfigurationTarget.WorkspaceFolder)
.then(undefined, e => this._log.exceptionS(e));
if (oldVals.globalValue !== undefined)
this._new
.update(newName, oldVals.globalValue, vscode.ConfigurationTarget.Global)
.then(undefined, e => this._log.exceptionS(e));

if (oldVals.workspaceValue !== undefined)
this._new
.update(newName, oldVals.workspaceValue, vscode.ConfigurationTarget.Workspace)
.then(undefined, e => this._log.exceptionS(e));

if (oldVals.workspaceFolderValue !== undefined)
this._new
.update(newName, oldVals.workspaceFolderValue, vscode.ConfigurationTarget.WorkspaceFolder)
.then(undefined, e => this._log.exceptionS(e));

if (oldVals.globalValue !== undefined)
this._old
.update(oldName, undefined, vscode.ConfigurationTarget.Global)
.then(undefined, e => this._log.exceptionS(e));

if (oldVals.workspaceValue !== undefined)
this._old
.update(oldName, undefined, vscode.ConfigurationTarget.Workspace)
.then(undefined, e => this._log.exceptionS(e));

if (oldVals.workspaceFolderValue !== undefined)
this._old
.update(oldName, undefined, vscode.ConfigurationTarget.WorkspaceFolder)
.then(undefined, e => this._log.exceptionS(e));

return oldVal;
} else {
Expand Down
1 change: 1 addition & 0 deletions test/Configurations.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ describe(path.basename(__filename), function () {
});

it('discovery.gracePeriodForMissing', function () {
this.timeout(10000);
return settings.updateConfig('discovery.gracePeriodForMissing', 9876).then(function () {
assert.equal((adapter as any) /* eslint-disable-line */._shared.execWatchTimeout, 9876000);
});
Expand Down
1 change: 1 addition & 0 deletions test/ExecutablesVariable.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ describe(path.basename(__filename), function () {

specify('resolving relative defaultCwd', async function () {
this.slow(1000);
this.timeout(10000);
await settings.updateConfig('test.executables', example1.suite1.execPath);
await settings.updateConfig('test.workingDirectory', 'defaultCwdStr');

Expand Down