I'm trying to implement jasmine report to my framework that work with Protractor so in the conf.js i put this code
onComplete: function(){
var browserName;
var capsPromise = browser.getCapabilities();
capsPromise.then(function (caps) {
browserName = caps.get('firefox');
var HTMLReport = require('protractor-html-reporter');
testConfig = {
reportTitle: 'Test Execution Report',
outPath: '/test/e2e/reports',
testBrowser: browserName,
modifiedSuiteName: false
};
new HTMLReport().from('xmlresults.xml', testConfig);
});
},
I already install jasmine reporter with this command
npm install --save-dev jasmine-reporters@^2.0.0
When I execute my script is not failing but when the execution try to generate the report in the terminal is displaying this:
E/launcher - ENOENT: no such file or directory, open 'xmlresults.xml'
E/launcher - Error: ENOENT: no such file or directory, open 'xmlresults.xml'
Is anybody has an idea what is happen with this error?
Hope you can help me.
Yes, the file cannot be opened at the path you specified because relative to whatever working directory you are in it isn't there.
Change the path to match the relative target location of your XML results file.