-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
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
ERR_IPC_CHANNEL_CLOSED when autoMerge set to true. #61
Comments
The Project-Repo doesn't exist anymore. |
@kpmck hello. Have you found the solution? |
@AM1988 I have done the following: #64 (comment) |
@brabenetz thank you, will try this. And could you please share the info about how your cypress/plugins/index.js look like? |
// Plugins enable you to tap into, modify, or extend the internal behavior of Cypress
// For more info, visit https://on.cypress.io/plugins-api
// https://www.npmjs.com/package/cypress-cucumber-preprocessor#typeScript-support
/* eslint-disable @typescript-eslint/no-var-requires */
// cucumber
const browserify = require('@cypress/browserify-preprocessor');
const cucumber = require('cypress-cucumber-preprocessor').default;
const resolve = require('resolve');
// reportportal
const registerReportPortalPlugin = require('@reportportal/agent-js-cypress/lib/plugin');
// cypress-mochawesome-reporter
const { beforeRunHook, afterRunHook } = require('cypress-mochawesome-reporter/lib');
module.exports = (on, config) => {
// enable cypress-mochawesome-reporter:
on('before:run', async (details) => {
await beforeRunHook(details);
});
on('after:run', async () => {
await afterRunHook();
});
// enable cucumber:
const preprocessorOptions = {
...browserify.defaultOptions,
typescript: resolve.sync('typescript', { baseDir: config.projectRoot }),
};
on('file:preprocessor', cucumber(preprocessorOptions));
// enable report-portal only on Jenkins:
const reportPortalJson = process.env.REPORTPORTAL_JSON;
if (reportPortalJson) {
// add reportPortal Config
const reportportalAttributes = JSON.parse(reportPortalJson);
const options = {
endpoint: ...,
token: ...,
launch: '...,
project: ...,
description: ...,
autoMerge: true,
attributes: [...],
restClientConfig: {
// timoutconfig: https://github.com/reportportal/client-javascript#timeout-30000ms-on-axios-requests
timeout: 900000, // (15m) default 30000 (30s)
},
};
config.reporterOptions.reporterEnabled = config.reporterOptions.reporterEnabled + ', @reportportal/agent-js-cypress';
config.reporterOptions.reportportalAgentJsCypressReporterOptions = options;
// enable reportPortal plugin
registerReportPortalPlugin(on, config);
}
return config;
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I have an Angular Nx project with Cypress. When I did not set autoMerge, the tests ran and were all reported to my instance of ReportPortal.
Once I switched to autoMerge, the first spec file ran successfully, and the second (and subsequent) spec files failed out with the ERR_IPC_CHANNEL_CLOSED failure, causing only the first spec file to run.
I was able to get the autoMerge to run successfully a handful of times, but once any change was made to the Cypress.json file, I was not able to get it to run again.
I have included a repo where this can be reproduced: https://github.com/kpmck/angular-nx-cypress-reportportal
Steps to reproduce:
npm i
to install packagesng e2e
to execute e2e testsCypress: 4.12.1 (I have also tried 5.4.0 and 4.1.0)
Node: 8.9.5
reportportal/agent-js-cypress: 5.0.1
The text was updated successfully, but these errors were encountered: