reportportal / agent-js-webdriverio

Agent to integrate Webdriver.io with ReportPortal.
https://www.npmjs.com/package/@reportportal/agent-js-webdriverio
Apache License 2.0
8 stars 2 forks source link

Finished launch doesn't set correct launch status on UI #52

Closed MadSandwich closed 1 year ago

MadSandwich commented 1 year ago

After success or failed test execution, Report Portal doesn't set finished time. Inside suite item:

Screenshot 2023-11-09 at 14 55 33

On the specific launch page:

Screenshot 2023-11-09 at 14 57 37

On all launches page:

Screenshot 2023-11-09 at 14 59 33

For the settings reference was used: https://github.com/reportportal/examples-js/blob/main/example-webdriverio/examples-webdriverio-mocha/wdio.conf.js

Debug logs(doesn't contains any issues):

RUNNING in iOS - file:///tests/e2e/Login/login.e2e.spec.ts
Start launch with tempId 3sb3z20kglor6r1ap {
  description: undefined,
  attributes: [
    { key: 'Platform', value: 'XXX' },
    {
      key: 'agent',
      value: '@reportportal/agent-js-webdriverio|5.0.3',
      system: true
    }
  ],
  rerun: undefined,
  rerunOf: undefined,
  mode: 'DEFAULT'
}
Success start launch with tempId 3sb3z20kglor6r1ap { id: 'f8f4408f-d56c-4c47-9d13-d893380bc456', number: 7 }
Start test item with tempId 3sb3z20kglor6r1au {
  startTime: 1699534147926,
  name: 'Authentication',
  type: 'SUITE',
  codeRef: 'tests/e2e/Login/login.e2e.spec.ts/Authentication',
  testCaseId: 'tests/e2e/Login/login.e2e.spec.ts/Authentication',
  launchUuid: 'f8f4408f-d56c-4c47-9d13-d893380bc456'
}
Success start item with tempId 3sb3z20kglor6r1au {
  id: 'c8337cb9-72d8-41c7-a70d-d3368c08ab43',
  uniqueId: 'auto:d211628e5953f8b1169dfd5221bd7781'
}
Start test item with tempId 3sb3z20kglor6r1av {
  startTime: 1699534147927,
  name: 'Log in without biometrics',
  type: 'STEP',
  codeRef: 'tests/e2e/Login/login.e2e.spec.ts/Authentication/Log in without biometrics',
  testCaseId: 'tests/e2e/Login/login.e2e.spec.ts/Authentication/Log in without biometrics',
  launchUuid: 'f8f4408f-d56c-4c47-9d13-d893380bc456'
}
Success start item with tempId 3sb3z20kglor6r1av {
  id: '613295fb-48b7-49fe-bda5-40cec2bcea58',
  uniqueId: 'auto:f1709df5a6f0786e70701bb25d5615e7'
}
Finish all children for test item with tempId 3sb3z20kglor6r1av 
Finish test item with tempId 3sb3z20kglor6r1av { status: 'passed' }
Finish test item with tempId 3sb3z20kglor6r1av {
  promiseStart: Promise {
    {
      id: '613295fb-48b7-49fe-bda5-40cec2bcea58',
      uniqueId: 'auto:f1709df5a6f0786e70701bb25d5615e7'
    }
  },
  realId: '613295fb-48b7-49fe-bda5-40cec2bcea58',
  children: [],
  finishSend: true,
  promiseFinish: Promise { <pending> },
  resolveFinish: [Function (anonymous)],
  rejectFinish: [Function (anonymous)]
}
Finish all children for test item with tempId 3sb3z20kglor6r1au 
Success finish item with tempId 3sb3z20kglor6r1av {
  message: "TestItem with ID = '613295fb-48b7-49fe-bda5-40cec2bcea58' successfully finished."
}
Successfully finish child with tempId 3sb3z20kglor6r1av
                 of test item with tempId 3sb3z20kglor6r1au 
Finish test item with tempId 3sb3z20kglor6r1au {}
Finish test item with tempId 3sb3z20kglor6r1au {
  promiseStart: Promise {
    {
      id: 'c8337cb9-72d8-41c7-a70d-d3368c08ab43',
      uniqueId: 'auto:d211628e5953f8b1169dfd5221bd7781'
    }
  },
  realId: 'c8337cb9-72d8-41c7-a70d-d3368c08ab43',
  children: [ '3sb3z20kglor6r1av' ],
  finishSend: true,
  promiseFinish: Promise { <pending> },
  resolveFinish: [Function (anonymous)],
  rejectFinish: [Function (anonymous)]
}
Success finish item with tempId 3sb3z20kglor6r1au {
  message: "TestItem with ID = 'c8337cb9-72d8-41c7-a70d-d3368c08ab43' successfully finished."
}
Finish launch with tempId 3sb3z20kglor6r1ap { endTime: 1699534177243 }
PASSED in iOS - file:///tests/e2e/Login/login.e2e.spec.ts
MadSandwich commented 1 year ago

Solved by adding a property into wdio config, to increase time

reporterSyncInterval: 30 * 1000, // in ms. default 5000