From ba57848cdd8868778a4c21d2aeaa29d3f8ec2081 Mon Sep 17 00:00:00 2001 From: Jackson Harper Date: Fri, 31 Mar 2023 09:51:35 +0800 Subject: [PATCH] Add test for telegram pages --- .../telegr.ph/expected-metadata.json | 11 ++ .../test/test-pages/telegr.ph/expected.html | 18 +++ .../test/test-pages/telegr.ph/source.html | 115 ++++++++++++++++++ .../test/test-pages/telegr.ph/url.txt | 1 + 4 files changed, 145 insertions(+) create mode 100644 packages/readabilityjs/test/test-pages/telegr.ph/expected-metadata.json create mode 100644 packages/readabilityjs/test/test-pages/telegr.ph/expected.html create mode 100644 packages/readabilityjs/test/test-pages/telegr.ph/source.html create mode 100644 packages/readabilityjs/test/test-pages/telegr.ph/url.txt diff --git a/packages/readabilityjs/test/test-pages/telegr.ph/expected-metadata.json b/packages/readabilityjs/test/test-pages/telegr.ph/expected-metadata.json new file mode 100644 index 000000000..9f6c15299 --- /dev/null +++ b/packages/readabilityjs/test/test-pages/telegr.ph/expected-metadata.json @@ -0,0 +1,11 @@ +{ + "title": "Duplicates the title in the text", + "byline": "@me", + "dir": null, + "excerpt": "Suggestions for improving text processing", + "siteName": "Telegraph", + "siteIcon": "http://fakehost/favicon.ico?1", + "publishedDate": "2023-03-24T09:52:08.000Z", + "language": "English", + "readerable": false +} diff --git a/packages/readabilityjs/test/test-pages/telegr.ph/expected.html b/packages/readabilityjs/test/test-pages/telegr.ph/expected.html new file mode 100644 index 000000000..76dd1b9d0 --- /dev/null +++ b/packages/readabilityjs/test/test-pages/telegr.ph/expected.html @@ -0,0 +1,18 @@ +
+
+
+
+
+ +
+
+
+
+
@me
+

Suggestions for improving text processing

+
+
+
+
+
\ No newline at end of file diff --git a/packages/readabilityjs/test/test-pages/telegr.ph/source.html b/packages/readabilityjs/test/test-pages/telegr.ph/source.html new file mode 100644 index 000000000..4e10f2498 --- /dev/null +++ b/packages/readabilityjs/test/test-pages/telegr.ph/source.html @@ -0,0 +1,115 @@ + + + + + + Duplicates the title in the text  – Telegraph + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+
+
+

+ Duplicates the title in the text  +

+
+ +
+
+
+
+

+ Duplicates the title in the text  +

+
+ @me +
+

+
+

+

+ Suggestions for improving text processing +

+

+
+

+
+
+ +
+
+ +
+
+
+ +
+
+
+
+
+ +
+
+
+ +
+
+
+
+ + + + + + + + + + diff --git a/packages/readabilityjs/test/test-pages/telegr.ph/url.txt b/packages/readabilityjs/test/test-pages/telegr.ph/url.txt new file mode 100644 index 000000000..826f319df --- /dev/null +++ b/packages/readabilityjs/test/test-pages/telegr.ph/url.txt @@ -0,0 +1 @@ +https://telegra.ph/Duplicates-the-title-in-the-text-03-24 \ No newline at end of file