| 57 | } |
| 58 | |
| 59 | function htmlReport (config, userConfig) { |
| 60 | config.html_report = path.join(config.projectPath, 'backstop_data', 'html_report'); |
| 61 | config.openReport = userConfig.openReport === undefined ? true : userConfig.openReport; |
| 62 | config.archivePath = path.join(config.projectPath, 'backstop_data', 'reports'); |
| 63 | config.archiveReport = userConfig.archiveReport === undefined ? false : userConfig.archiveReport; |
| 64 | |
| 65 | if (userConfig.paths) { |
| 66 | config.html_report = userConfig.paths.html_report || config.html_report; |
| 67 | config.archivePath = userConfig.paths.reports_archive || config.archivePath; |
| 68 | } |
| 69 | |
| 70 | config.compareConfigFileName = path.join(config.html_report, 'config.js'); |
| 71 | config.compareReportURL = path.join(config.html_report, 'index.html'); |
| 72 | } |
| 73 | |
| 74 | function jsonReport (config, userConfig) { |
| 75 | config.json_report = path.join(config.projectPath, 'backstop_data', 'json_report'); |