Skip to content

Tests are hanging in an in progress state when retries is greater than 0 #85

Open
@costa-collibra

Description

@costa-collibra

Here is the config:

const testTags = process.env.TAGS ? process.env.TAGS : 'All';

const RPconfig = {
  token: process.env.REPORT_PORTAL_API_KEY,
  endpoint: process.env.REPORT_PORTAL_URL,
  project: process.env.PROJECT_NAME,
  launch: `${process.env.BRANCH_NAME} - ${process.env.BUILD_NUMBER}`,
  attributes: [
    {
      key: 'branchName',
      value: process.env.BRANCH_NAME,
    },
    {
      key: 'testTags',
      value: testTags,
    },
  ],
  description: 'E2E Playwright test launch',
};

const reportList: ReporterDescription[] = [
  ['list'],
  ['html', { open: 'never' }],
  ['line'],
];

if (process.env.CI === 'true') {
  reportList.push(['./utils/CiReporter.ts']);
  reportList.push(['@reportportal/agent-js-playwright', RPconfig]);
}

const config: PlaywrightTestConfig = {
  testDir: './tests',
  timeout: 2 * 60 * 1000,
  expect: {
    timeout: 5000,
  },
  fullyParallel: true,
  retries: process.env.CI === 'true' ? 1 : 0, // report portal issue when retries is > 0
  workers: process.env.CI === 'true' ? 5 : 1,
  forbidOnly: process.env.CI === 'true',
  reporter: reportList,
  outputDir: 'test-assets/',
  use: {
    browserName: 'chromium',
    headless: process.env.CI === 'true',
    screenshot: {
      mode: 'only-on-failure',
      fullPage: true,
    },
    video: 'retain-on-failure',
    actionTimeout: 5000,
    navigationTimeout: 30000,
    baseURL: process.env.BASE_URL,
    trace: 'retain-on-failure',
    launchOptions: {
      slowMo: 0,
    },
  },
};

export default config;

Report portal results just hang in progress and have to be force stopped.

However when retries is 0 it works.

Please can someone investigate?

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingworkaroundThe workaround available to avoid the bug

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions