Skip to content

Commit 2308ebf

Browse files
committed
Final stuff to revert
1 parent 8da608d commit 2308ebf

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

test/setup.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ expect.extend({
3333
toHaveDiagnostics(diagnostics: ts.Diagnostic[]): jest.CustomMatcherResult {
3434
expect(diagnostics).toBeInstanceOf(Array);
3535
// @ts-ignore
36-
const matcherHint = this.utils.matcherHint("toHaveErrorDiagnostics", undefined, "", this);
36+
const matcherHint = this.utils.matcherHint("toHaveDiagnostics", undefined, "", this);
3737

3838
const diagnosticMessages = ts.formatDiagnosticsWithColorAndContext(diagnostics, {
3939
getCurrentDirectory: () => "",

test/unit/modules/resolution.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ test("doesn't resolve paths out of root dir", () => {
8282
.setMainFileName("src/main.ts")
8383
.setOptions({ rootDir: "./src" })
8484
.disableSemanticCheck()
85-
.expectToHaveErrorDiagnostics();
85+
.expectToHaveDiagnostics();
8686
});
8787

8888
test.each([

test/util.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -350,13 +350,13 @@ export abstract class TestBuilder {
350350
return this;
351351
}
352352

353-
public expectToHaveErrorDiagnostics(): this {
353+
public expectToHaveDiagnostics(): this {
354354
expect(this.getLuaDiagnostics()).toHaveDiagnostics();
355355
return this;
356356
}
357357

358358
public expectToHaveDiagnosticOfError(error: Error): this {
359-
this.expectToHaveErrorDiagnostics();
359+
this.expectToHaveDiagnostics();
360360
expect(this.getLuaDiagnostics()).toHaveLength(1);
361361
const firstDiagnostic = this.getLuaDiagnostics()[0];
362362
expect(firstDiagnostic).toMatchObject({ messageText: error.message });

0 commit comments

Comments
 (0)