Closed Vooha-QualiTlabs closed 2 years ago
@Dmitry-Ostashev Please take a look into this issue. Thanks
Thank you for your report. I reproduced this problem with a simple test. This issue looks similar to this: https://github.com/DevExpress/testcafe/issues/6886.
Thank you for your response @Dmitry-Ostashev . May I know what could be the time estimation for this fix? thank you.
Any personal estimate may be misleading, so we cannot currently tell it at the moment. Once we get any results, we will post them in this thread.
The issue can be reproduced with the local browser:
testcafe ie test.js
fixture `Screenshot`
.page('https://google.com');
test('Take screenshot', async t => {
await t.takeScreenshot();
});
Thank you for fixing, @miherlosev . The screenshots are working in this version npm i testcafe@1.18.5-alpha.1
What is your Scenario?
I am creating a custom reporter at my end. The tests to be run in the Lambda Test. I have created a report to get the screenshots whenever the test fails.
What is the Current behavior?
The testRunInfo shows warning
What is the Expected behavior?
The screenshots should be captured without any issue
What is your public website URL? (or attach your complete example)
https://www.xeniapp.com/
What is your TestCafe test code?
It is happening for any test
Your complete configuration file
{ "selectorTimeout": 90000, "pageLoadTimeout": 90000, "browserInitTimeout": 180000, "assertionTimeOut": 90000, "disableMultipleWindows": true, "skipJsErrors": true, "concurrency": 1, "speed": 1, "stopOnFirstFail": false, "quarantineMode":{ "successThreshold":1, "attemptLimit": 2 }, "screenshotPath": "/screenshots/", "screenshots": { "takeOnFails": true, "fullPage": true, "pathPattern": "${DATE}/test-${TEST_INDEX}/${FILE_INDEX}.png"
}
}
Your complete test report
Test Run Info:
{ errs: [)\n' +
' at processTicksAndRejections (internal/process/task_queues.js:95:5)\n' +
' at C:\Users\LENOVO\qaautomation\node_modules\testcafe\src\screenshots\capturer.js:152:34\n' +
TestRunErrorFormattableAdapter { userAgent: 'Chrome 98.0.4758.102 / Windows 10 ( https://automation.lambdatest.com/logs/?sessionID=e40d33f6fe0ce21c05486ae9875529da )', screenshotPath: '', testRunId: 's1EQippPj', testRunPhase: 'inTest', code: 'E53', isTestCafeError: true, callsite: [CallsiteRecord], errMsg: "AssertionError: not exactly matching with given location : Hyderabd: expected 'hyd- hyderabad, all airports' to include 'hyderabd'", diff: false, id: 'wBAieQe' } ], warnings: [ 'Was unable to take a screenshot due to an error.\n' + '\n' + 'RangeError [ERR_OUT_OF_RANGE]: The value of "sourceStart" is out of range. It must be >= 0. Received -7387924\n' + ' at _copy (buffer.js:227:13)\n' + ' at Buffer.copy (buffer.js:768:12)\n' + ' at Object.copyImagePart (C:\Users\LENOVO\qaautomation\node_modules\testcafe\src\screenshots\utils.js:50:23)\n' + ' at Object.cropScreenshot (C:\Users\LENOVO\qaautomation\node_modules\testcafe\src\screenshots\crop.js:140:12)\n' + ' at runMicrotasks (
' at Capturer._capture (C:\Users\LENOVO\qaautomation\node_modules\testcafe\src\screenshots\capturer.js:133:9)\n' + ' at Capturer.captureError (C:\Users\LENOVO\qaautomation\node_modules\testcafe\src\screenshots\capturer.js:190:16)\n' + ' at BrowserManipulationQueue._takeScreenshot (C:\Users\LENOVO\qaautomation\node_modules\testcafe\src\test-run\browser-manipulation-queue.js:55:20)' ], durationMs: 81471, unstable: false, screenshotPath: null, screenshots: [], videos: [], quarantine: { '1': { passed: false }, '2': { passed: false } }, skipped: false, browsers: [ { testRunId: 's1EQippPj', name: 'Chrome', version: '98.0.4758.102', platform: 'desktop', os: [Object], engine: [Object], prettyUserAgent: 'Chrome 98.0.4758.102 / Windows 10', userAgent: 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.102 Safari/537.36', alias: 'lambdatest:Chrome@98.0:Windows', headless: false } ], testId: 'YAv2QFu' }
Screenshots
No response
Steps to Reproduce
TestCafe version
1.18.3
Node.js version
14.17.4
Command-line arguments
testcafe lambdatest:Chrome@98.0:Windows 10 src/tests/*.js --skip-js-errors --reporter my-custom-reporter
Browser name(s) and version(s)
Chrome 98
Platform(s) and version(s)
Windows 10
Other
No response