From 273299693b85996878907ad256ed55f072ec3f1a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lauren=C8=9Biu=20Nicola?= Date: Mon, 9 Dec 2019 20:57:55 +0200 Subject: Code: enable prettier trailing commas --- .../utils/diagnotics/SuggestedFixCollection.test.ts | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'editors/code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts') diff --git a/editors/code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts b/editors/code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts index f0328893e..4c1467b57 100644 --- a/editors/code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts +++ b/editors/code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts @@ -8,20 +8,20 @@ const uri1 = vscode.Uri.file('/file/1'); const uri2 = vscode.Uri.file('/file/2'); const mockDocument1 = ({ - uri: uri1 + uri: uri1, } as unknown) as vscode.TextDocument; const mockDocument2 = ({ - uri: uri2 + uri: uri2, } as unknown) as vscode.TextDocument; const range1 = new vscode.Range( new vscode.Position(1, 2), - new vscode.Position(3, 4) + new vscode.Position(3, 4), ); const range2 = new vscode.Range( new vscode.Position(5, 6), - new vscode.Position(7, 8) + new vscode.Position(7, 8), ); const diagnostic1 = new vscode.Diagnostic(range1, 'First diagnostic'); @@ -32,7 +32,7 @@ function suggestion1(): SuggestedFix { return new SuggestedFix( 'Replace me!', new vscode.Location(uri1, range1), - 'With this!' + 'With this!', ); } @@ -44,7 +44,7 @@ describe('SuggestedFixCollection', () => { // Specify the document and range that exactly matches const codeActions = suggestedFixes.provideCodeActions( mockDocument1, - range1 + range1, ); assert.strictEqual(codeActions.length, 1); @@ -66,7 +66,7 @@ describe('SuggestedFixCollection', () => { const codeActions = suggestedFixes.provideCodeActions( mockDocument1, - range2 + range2, ); assert(!codeActions || codeActions.length === 0); @@ -78,7 +78,7 @@ describe('SuggestedFixCollection', () => { const codeActions = suggestedFixes.provideCodeActions( mockDocument2, - range1 + range1, ); assert(!codeActions || codeActions.length === 0); @@ -91,7 +91,7 @@ describe('SuggestedFixCollection', () => { const codeActions = suggestedFixes.provideCodeActions( mockDocument1, - range1 + range1, ); assert(!codeActions || codeActions.length === 0); @@ -106,7 +106,7 @@ describe('SuggestedFixCollection', () => { const codeActions = suggestedFixes.provideCodeActions( mockDocument1, - range1 + range1, ); assert.strictEqual(codeActions.length, 1); -- cgit v1.2.3 From 0e9cabab3fb4c15fb1b88e62a35ccf1ea52ef853 Mon Sep 17 00:00:00 2001 From: Tetsuharu OHZEKI Date: Thu, 12 Dec 2019 00:49:54 +0900 Subject: Enable noImplicitReturns option for vscode extension --- .../code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'editors/code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts') diff --git a/editors/code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts b/editors/code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts index 4c1467b57..ef09013f4 100644 --- a/editors/code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts +++ b/editors/code/src/test/utils/diagnotics/SuggestedFixCollection.test.ts @@ -53,7 +53,8 @@ describe('SuggestedFixCollection', () => { const { diagnostics } = codeAction; if (!diagnostics) { - return assert.fail('Diagnostics unexpectedly missing'); + assert.fail('Diagnostics unexpectedly missing'); + return; } assert.strictEqual(diagnostics.length, 1); @@ -114,7 +115,8 @@ describe('SuggestedFixCollection', () => { const { diagnostics } = codeAction; if (!diagnostics) { - return assert.fail('Diagnostics unexpectedly missing'); + assert.fail('Diagnostics unexpectedly missing'); + return; } // We should be associated with both diagnostics -- cgit v1.2.3