瀏覽代碼

Use new HTML purge script for test code

jherve 1 年之前
父節點
當前提交
6358c83e15
共有 5 個文件被更改,包括 3699 次插入501 次删除
  1. 3 2
      test/ArtDecoCard.purs
  2. 1 0
      test/JobsUnifiedTopCard.purs
  3. 3432 0
      test/examples/andrew_ng_experiences.html
  4. 261 498
      test/examples/job_offer_3786945580.html
  5. 2 1
      test/pruneHtml.js

File diff suppressed because it is too large
+ 3 - 2
test/ArtDecoCard.purs


+ 1 - 0
test/JobsUnifiedTopCard.purs

@@ -20,6 +20,7 @@ import Type.Proxy (Proxy(..))
 
 type TestCase a = { detached ∷ a DetachedNode , filePath ∷ String , output ∷ Output }
 
+-- Original URL : https://www.linkedin.com/jobs/view/3786945580/
 jobOfferPage_3786945580 ∷ TestCase JobOfferPage
 jobOfferPage_3786945580 = {
   filePath: "test/examples/job_offer_3786945580.html",

File diff suppressed because it is too large
+ 3432 - 0
test/examples/andrew_ng_experiences.html


File diff suppressed because it is too large
+ 261 - 498
test/examples/job_offer_3786945580.html


+ 2 - 1
test/pruneHtml.js

@@ -1,7 +1,8 @@
 #! /usr/bin/env node
 
 // This can be called with e.g. `test/pruneHtml.js path/to/the/file.html`
-// The same file can then be prettified using `npx prettier --parser html --print-width 250 -w path/to/the/file.html`
+// The output file should not be prettified since it would mess up with line breaks and change 
+// the value of both "textContent" / "innerHTML".
 
 const fs = require("fs");
 const url = require("url");