Skip to content
Snippets Groups Projects
Unverified Commit 5f9298e1 authored by filipe-dias's avatar filipe-dias Committed by GitHub
Browse files

Merge pull request #376 from visual-framework/feature/visual-regression-testing

adds visual regression testing process
parents 83c32a03 dc6214b3
No related branches found
No related tags found
No related merge requests found
Pipeline #18454 passed with stages
in 3 minutes and 3 seconds
Showing
with 62 additions and 0 deletions
......@@ -7,3 +7,5 @@ build
public
components/**/*.css
*.tgz
backstop_data/html_report/
bitmaps_test/
var glob = require("glob")
var viewports = [
{
"name": "small",
"width": 375,
"height": 667
},
{
"name": "medium",
"width": 768,
"height": 1024
},
{
"name": "huge",
"width": 1366,
"height": 768
}
];
// Hide any selectors you don't need
var hideSelectors = [];
// Take out any selectors
var removeSelectors = [];
// Just get look at these selectors
var selectors = [];
var scenariosArray = [];
var htmlFiles = glob.sync("build/components/preview/**/*.html");
// Loop through all *.html pages and push to scenariosArray
htmlFiles.forEach(function(file, i) {
var filename = file;
scenariosArray.push({
"label": filename,
"url": "http://localhost:8888/"+filename,
"hideSelectors": hideSelectors,
"removeSelectors": removeSelectors,
"selectors": selectors,
"delay": 500
});
});
module.exports = {
"id": "SCL Test",
"viewports": viewports,
"scenarios": scenariosArray,
"paths": {
"bitmaps_reference": "backstop_data/bitmaps_reference",
"bitmaps_test": "backstop_data/bitmaps_test",
"casper_scripts": "backstop_data/casper_scripts",
"html_report": "backstop_data/html_report",
"ci_report": "backstop_data/ci_report"
},
"casperFlags": [],
"engine": "phantomjs",
"report": ["browser"],
"debug": false
}
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment