@centreon/js-config 26.7.4 → 26.7.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cypress/e2e/commands.ts +2 -2
- package/cypress/e2e/tasks.ts +9 -0
- package/package.json +1 -1
package/cypress/e2e/commands.ts
CHANGED
|
@@ -642,8 +642,8 @@ Cypress.Commands.add(
|
|
|
642
642
|
cy.log(`Getting logs from container ${name} ...`);
|
|
643
643
|
|
|
644
644
|
return cy.getLogDirectory().then((logDirectory) => {
|
|
645
|
-
let sourcePhpLogs = '/var/log/
|
|
646
|
-
let targetPhpLogs = `${logDirectory}/
|
|
645
|
+
let sourcePhpLogs = '/var/log/centreon/prod.web.log';
|
|
646
|
+
let targetPhpLogs = `${logDirectory}/prod.web.log`;
|
|
647
647
|
let sourceApacheLogs = '/var/log/apache2';
|
|
648
648
|
let targetApacheLogs = `${logDirectory}/apache2`;
|
|
649
649
|
if (Cypress.env('WEB_IMAGE_OS').includes('alma')) {
|
package/cypress/e2e/tasks.ts
CHANGED
|
@@ -240,6 +240,15 @@ export default (on: Cypress.PluginEvents): void => {
|
|
|
240
240
|
} catch (error) {
|
|
241
241
|
console.error(error);
|
|
242
242
|
|
|
243
|
+
// Best-effort teardown: keep the original startup error if cleanup fails.
|
|
244
|
+
try {
|
|
245
|
+
await dockerEnvironment?.down();
|
|
246
|
+
} catch (teardownError) {
|
|
247
|
+
console.error(teardownError);
|
|
248
|
+
} finally {
|
|
249
|
+
dockerEnvironment = null;
|
|
250
|
+
}
|
|
251
|
+
|
|
243
252
|
throw error;
|
|
244
253
|
}
|
|
245
254
|
},
|