diff --git a/automation/tests/settingsTests.test.js b/automation/tests/settingsTests.test.js index 89ff778f4..f88c8bda7 100644 --- a/automation/tests/settingsTests.test.js +++ b/automation/tests/settingsTests.test.js @@ -50,7 +50,7 @@ test.describe('Settings tests', () => { }); test.afterEach(async ({}, testInfo) => { - if (testInfo.status === 'passed') { + if (testInfo.status !== 'passed') { const screenshotPath = `./test-results/screenshots/${testInfo.title.replace(/\s+/g, '_')}.png`; await window.screenshot({ path: screenshotPath }); console.log(`Screenshot saved: ${screenshotPath}`);