sschmid 5 年之前
父節點
當前提交
df3601705b
共有 1 個文件被更改,包括 4 次插入2 次删除
  1. 4 2
      test/Util/generateImages_browserless.js

+ 4 - 2
test/Util/generateImages_browserless.js

@@ -6,9 +6,11 @@
 
   This can be used to generate PNGs from OSMD without a browser.
   It's also used with the visual regression test system in
-  `tools/visual_regression.sh`.
+  `tools/visual_regression.sh`
+  (see package.json, used with npm run generate:blessed and generate:current, then test:visual).
 
-  Note: this script needs to "fake" quite a few browser elements, like window, document, and a Canvas HTMLElement.
+  Note: this script needs to "fake" quite a few browser elements, like window, document, and a Canvas HTMLElement,
+  which otherwise are missing in pure nodejs, causing errors in OSMD.
   For that it needs the canvas package installed.
   There are also some hacks needed to set the container size (offsetWidth) correctly.