Visual regression test tool with html reporter.
Table of Contents
- Node.js v6+
reg-cli support Node.js v6+
$ npm i -D reg-cli
$ reg-cli /path/to/actual-dir /path/to/expected-dir /path/to/diff-dir -R ./report.html
--updateUpdate expected images.(Copy `actual images` to `expected images`).
--reportOutput html report to specified directory.
--jsonSpecified json report path. If omitted
--ignoreChangeIf true, error will not be thrown when image change detected.
--urlPrefixAdd prefix to all image src.
--matchingThresholdMatching threshold, ranges from 0 to 1. Smaller values make the comparison more sensitive. 0 by default.
--thresholdRateRate threshold for detecting change. When the difference ratio of the image is larger than the set rate detects the change. Applied after
--thresholdPixelPixel threshold for detecting change. When the difference pixel of the image is larger than the set pixel detects the change. This value takes precedence over
thresholdRate. Applied after
--concurrencyHow many processes launches in parallel. If omitted 4.
--enableAntialiasEnable antialias. If omitted false.
--additionalDetection. Enable additional difference detection(highly experimental). Select "none" or "client" (default: "none").
-R option set, output html report to specified directory.
$ npm t
The MIT License (MIT)
Copyright (c) 2017 bokuweb
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.