Skip to content
This repository has been archived by the owner on Mar 29, 2022. It is now read-only.

Timeout option in testNG making log messages unsent #6

Closed
rbhbokka opened this issue Jan 11, 2017 · 3 comments
Closed

Timeout option in testNG making log messages unsent #6

rbhbokka opened this issue Jan 11, 2017 · 3 comments
Assignees

Comments

@rbhbokka
Copy link

rbhbokka commented Jan 11, 2017

Dependencies:
agent-java-testng:2.6.0
logger-java-log4j:2.6.0
logger-java-logback:2.6.0
org.testng:testng:6.9.8
org.apache.logging.log4j:log4j-core:2.4

Bug description:
User use testNG as a test runner. If test item have a timeout, log is not being sent to RP.

<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" >
<suite name="Menu" verbose="1" time-out="1">

Looks like this issue is related to a testng-team/testng#914

TestNG creating separate threads for all test items if timeout is set. Then we have situation while runningNowItemId field in ReportPortalListenerContext.java is being set from test item thread, and read from main thread on a log message creation. As runningNowItemId is a ThreadLocal object we will get null value in main thread.

@avarabyeu avarabyeu self-assigned this Jan 13, 2017
@avarabyeu
Copy link
Member

avarabyeu commented Jan 13, 2017

testng-team/testng#914

@avarabyeu
Copy link
Member

@rbhbokka could you please check an issue with new client version (3.0.0)?

@avarabyeu
Copy link
Member

Since this component is not used anymore, closing the issue due to inactivity.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants