From 3f563de9c0ff6b8d4954006323ac8fc9521717cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=A9ry=20Debongnie?= Date: Wed, 22 Sep 2021 16:29:59 +0200 Subject: [PATCH] [CLEANUP] run prettier on codebase --- tests/component/class_style.test.ts | 2 +- tests/component/error_handling.test.ts | 12 +++++++----- tests/misc/portal.test.ts | 2 +- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/tests/component/class_style.test.ts b/tests/component/class_style.test.ts index 78be46e4..4cee0814 100644 --- a/tests/component/class_style.test.ts +++ b/tests/component/class_style.test.ts @@ -265,7 +265,7 @@ describe("class and style attributes with t-component", () => { error = e; } expect(error).toBeDefined(); - const regexp = /Cannot read properties of undefined \(reading 'crash'\)|Cannot read property 'crash' of undefined/g + const regexp = /Cannot read properties of undefined \(reading 'crash'\)|Cannot read property 'crash' of undefined/g; expect(error.message).toMatch(regexp); expect(fixture.innerHTML).toBe(""); }); diff --git a/tests/component/error_handling.test.ts b/tests/component/error_handling.test.ts index f87e84c8..378c11fc 100644 --- a/tests/component/error_handling.test.ts +++ b/tests/component/error_handling.test.ts @@ -95,7 +95,9 @@ describe("component error handling (catchError)", () => { try { await super.render(); } catch (e) { - expect(e.message).toMatch(/Cannot read properties of undefined \(reading 'this'\)|Cannot read property 'this' of undefined/); + expect(e.message).toMatch( + /Cannot read properties of undefined \(reading 'this'\)|Cannot read property 'this' of undefined/ + ); } } } @@ -359,7 +361,7 @@ describe("component error handling (catchError)", () => { error = e; } expect(error).toBeDefined(); - const regexp = /Cannot read properties of undefined \(reading 'crash'\)|Cannot read property 'crash' of undefined/g + const regexp = /Cannot read properties of undefined \(reading 'crash'\)|Cannot read property 'crash' of undefined/g; expect(error.message).toMatch(regexp); expect(console.error).toBeCalledTimes(0); @@ -470,7 +472,7 @@ describe("component error handling (catchError)", () => { error = e; } expect(error).toBeDefined(); - const regexp = /Cannot read properties of undefined \(reading 'crash'\)|Cannot read property 'crash' of undefined/g + const regexp = /Cannot read properties of undefined \(reading 'crash'\)|Cannot read property 'crash' of undefined/g; expect(error.message).toMatch(regexp); expect(console.error).toBeCalledTimes(0); @@ -497,7 +499,7 @@ describe("component error handling (catchError)", () => { error = e; } expect(error).toBeDefined(); - const regexp = /Cannot read properties of undefined \(reading 'crash'\)|Cannot read property 'crash' of undefined/g + const regexp = /Cannot read properties of undefined \(reading 'crash'\)|Cannot read property 'crash' of undefined/g; expect(error.message).toMatch(regexp); expect(console.error).toBeCalledTimes(0); @@ -521,7 +523,7 @@ describe("component error handling (catchError)", () => { error = e; } expect(error).toBeDefined(); - const regexp = /Cannot read properties of undefined \(reading 'y'\)|Cannot read property 'y' of undefined/g + const regexp = /Cannot read properties of undefined \(reading 'y'\)|Cannot read property 'y' of undefined/g; expect(error.message).toMatch(regexp); }); diff --git a/tests/misc/portal.test.ts b/tests/misc/portal.test.ts index 9cd1afa4..9cef2762 100644 --- a/tests/misc/portal.test.ts +++ b/tests/misc/portal.test.ts @@ -546,7 +546,7 @@ describe("Portal: Basic use and DOM placement", () => { error = e; } expect(error).toBeDefined(); - const regexp = /Cannot read properties of undefined \(reading 'crash'\)|Cannot read property 'crash' of undefined/g + const regexp = /Cannot read properties of undefined \(reading 'crash'\)|Cannot read property 'crash' of undefined/g; expect(error.message).toMatch(regexp); });