Output the screen shots on error, or do the step by step report and have it output to the output directory. The screenshot on error was working before we upgraded codeceptjs and webdriver. After upgrading, since the screen shots on error was not working, I went back to the release notes and then added the plugin's section to my codecept.json to try to get it to work. Any advice on what I may be doing wrong is appreciated.
Nothing.... just an empty output directory
[1] Starting <teardown> session
Emitted | test.failed ([object Object])
Emitted | test.finish ([object Object])
[1] <teardown> Stopping recording promises
» <screenshotOnFail> Test failed, saving screenshot
» Screenshot has been saved to C:\Users\me\source\repos\myProject\output\testname.failed.png, size: 1663x1255
× FAILED in 36834ms
"output": "./output",
"helpers": {
"WebDriver": {
"smartWait": 5000,
"host": "localhost",
"port": 4444,
"browser": "chrome",
"restart": false,
"url": "http://localhost",
"outputDir": "output",
"fullPageScreenshots": true,
"timeouts": {
"script": 60000,
"page load": 10000
},
"desiredCapabilities": {
"browserName": "chrome",
"chromeOptions": {
"args": [ "start-maximized" ],
"prefs": {
"profile.default_content_setting_values.cookies": 1,
"profile.block_third_party_cookies": false
}
}
}
}
},
"plugins": {
"screenshotOnFail": {
"enabled": true
},
"stepByStepReport": {
"enabled": true
}
},
"include": {
"I": "./steps_file.js",
"loginPage": "./page_objects/login.js",
"configInfo": "./load-test-configuration"
},
"mocha": {
"reporterOptions": {
"mocha-junit-reporter": {
"stdout": "-",
"options": {
"mochaFile": "output/result.xml"
}
},
"codeceptjs-cli-reporter": {
"stdout": "-",
"options": {
"verbose": true,
"steps": true
}
}
}
},
"hooks": [],
"gherkin": {
"features": "./features/**/*.feature",
"steps": [
"./step_definitions/steps.js",
"./step_definitions/some-other-file.js"
]
},
"tests": "./*_test.js",
"timeout": 10000,
"name": "namehere",
"siteURL": "urlhere"
} ```
What are you trying to achieve?
Output the screen shots on error, or do the step by step report and have it output to the output directory. The screenshot on error was working before we upgraded codeceptjs and webdriver. After upgrading, since the screen shots on error was not working, I went back to the release notes and then added the plugin's section to my codecept.json to try to get it to work. Any advice on what I may be doing wrong is appreciated.
What do you get instead?
Nothing.... just an empty output directory
Details