From 046ef964a955ab64579a8f9759d0bd86b2f2dcc7 Mon Sep 17 00:00:00 2001 From: Lina Tawfik Date: Wed, 28 May 2025 17:30:42 -0700 Subject: [PATCH] Format code with prettier --- rendered.html | 3 ++- test-markdown.json | 1 - test/sanitizer.test.ts | 18 ++++++++++-------- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/rendered.html b/rendered.html index 93d8125..532b035 100644 --- a/rendered.html +++ b/rendered.html @@ -1 +1,2 @@ -{"message":"Problems parsing JSON","documentation_url":"https://docs.github.com/rest/markdown/markdown#render-a-markdown-document","status":"400"} \ No newline at end of file +{"message":"Problems parsing +JSON","documentation_url":"https://docs.github.com/rest/markdown/markdown#render-a-markdown-document","status":"400"} diff --git a/test-markdown.json b/test-markdown.json index 030c003..6911008 100644 --- a/test-markdown.json +++ b/test-markdown.json @@ -3,4 +3,3 @@ "mode": "gfm", "context": "anthropics/claude-code-action" } -EOF < /dev/null \ No newline at end of file diff --git a/test/sanitizer.test.ts b/test/sanitizer.test.ts index 94e7bda..e6cd150 100644 --- a/test/sanitizer.test.ts +++ b/test/sanitizer.test.ts @@ -44,9 +44,9 @@ describe("stripMarkdownImageAltText", () => { expect(stripMarkdownImageAltText("![example alt text](image.png)")).toBe( "![](image.png)", ); - expect(stripMarkdownImageAltText("Text ![description](pic.jpg) more text")).toBe( - "Text ![](pic.jpg) more text", - ); + expect( + stripMarkdownImageAltText("Text ![description](pic.jpg) more text"), + ).toBe("Text ![](pic.jpg) more text"); }); it("should handle multiple images", () => { @@ -83,9 +83,9 @@ describe("stripMarkdownLinkTitles", () => { describe("stripHiddenAttributes", () => { it("should remove alt attributes", () => { - expect(stripHiddenAttributes('example text')).toBe( - '', - ); + expect( + stripHiddenAttributes('example text'), + ).toBe(''); expect(stripHiddenAttributes("example")).toBe( '', ); @@ -261,7 +261,9 @@ describe("sanitizeContent", () => { describe("stripHtmlComments (legacy)", () => { it("should remove HTML comments", () => { - expect(stripHtmlComments("Hello World")).toBe("Hello World"); + expect(stripHtmlComments("Hello World")).toBe( + "Hello World", + ); expect(stripHtmlComments("Text")).toBe("Text"); expect(stripHtmlComments("Text")).toBe("Text"); }); @@ -271,4 +273,4 @@ describe("stripHtmlComments (legacy)", () => { "Hello World", ); }); -}); \ No newline at end of file +});