We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I am experiencing issues with file uploads. Even the example from: https://github.com/reportportal/client-javascript/blob/master/examples/generateTestLaunch.js is not working. The headers are still set and sent, but it seems that ReportPortal is ignoring them.
When one checks the documentation: https://github.com/reportportal/documentation/blob/master/src/md/src/DevGuides/reporting.md#batch-save-logs it's stated, that all files should be uploaded at once.
Also the content type "multipart/form-data" which is used in JavaScript implementation is not mentioned in the example
The text was updated successfully, but these errors were encountered:
@KatsiarynaTatarynovich could you please check this issue?
Sorry, something went wrong.
@AmsterGet @KatsiarynaTatarynovich @evjlobanova could someone just provide an working example for the JavaScript client? I finally got it working with following:
const fsObject = fs.readFileSync(diffImageAbsolutePath); const contentBase64 = new Buffer(fsObject).toString('base64'); const fileObject = { name: 'testPair.diffImage.png', type: 'image/png', content: contentBase64, }; var sendLogObject = reportPortalClient.sendLog( testObject.tempId, { level: 'ERROR', message: 'Difference found', }, fileObject);
Hi @schrufygroovy Check out the following example for the agent-js-mocha - https://github.com/reportportal/examples-js/blob/master/example-mocha/spec/logTest.spec.js#L80 It uses the sendLog method from the client-javascript instance.
sendLog
Thanks for finding. It would be nice to mention this in the docs.
AmsterGet
No branches or pull requests
I am experiencing issues with file uploads. Even the example from: https://github.com/reportportal/client-javascript/blob/master/examples/generateTestLaunch.js is not working.
The headers are still set and sent, but it seems that ReportPortal is ignoring them.
When one checks the documentation: https://github.com/reportportal/documentation/blob/master/src/md/src/DevGuides/reporting.md#batch-save-logs
it's stated, that all files should be uploaded at once.
Also the content type "multipart/form-data" which is used in JavaScript implementation is not mentioned in the example
The text was updated successfully, but these errors were encountered: