[ 
https://issues.apache.org/jira/browse/SUREFIRE-681?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17029651#comment-17029651
 ] 

finn desolace commented on SUREFIRE-681:
----------------------------------------

[~tibordigana]

Following table should have 2 extra columns with timestamp of start and end 
time.

But is see these are the test classes, and not the specific tests.

!image-2020-02-04-09-38-40-174.png|width=1236,height=120!

So I'd have it also with the testcase*s.*
 I see they currently lack column names.

!image-2020-02-04-09-42-25-382.png|width=965,height=394!

 

As for the XSD you mentioned.   

I think it should be somewhat similar to "time".
I see it's three times mentioned in the xsd.
I'd guess it would be added accordingly

<xs:attribute name="time" type="SUREFIRE_TIME"/>
<xs:attribute name="starttime" type="date"/>
<xs:attribute name="endtime" type="date"/>

But it should not capture only the date, but a timestamp like [~cheng xu] 
mentioned
I guess SUREFIRE_TIME regex is for the elapsed time and not suited.
I'd prefer DD/MM/YYYY HH:mm:ss for the starttime and endtime

Maybe the timezoneidentifier like in log4js can pick up the right timezone so 
that it also matches the timezone of those generated logs.

Thanks in advance for your aid.

 

> Add timestamp when each test is run in the generated report
> -----------------------------------------------------------
>
>                 Key: SUREFIRE-681
>                 URL: https://issues.apache.org/jira/browse/SUREFIRE-681
>             Project: Maven Surefire
>          Issue Type: Improvement
>          Components: Maven Failsafe Plugin, Maven Surefire Plugin
>            Reporter: Viggo Navarsete
>            Priority: Major
>             Fix For: Backlog
>
>         Attachments: image-2020-02-04-09-38-40-174.png, 
> image-2020-02-04-09-42-25-382.png
>
>
> We run integration tests using maven-surefire-plugin by filtering on the 
> names (they end with *TestIntegration). These tests access a JBoss server, 
> and leave log entires in the server log. When a test fail, it would be great 
> to have a timestamp on each test in the test report from surefire so that it 
> can be matched against what is happening in the server log. This is 
> especially true when you have a lot of integration tests running and you 
> can't directly spot the server log entries related to the failing test. By 
> adding a timestamp to the tests it would make it MUCH easier to figure out 
> the server log dependent calls.
> Current output:
> {noformat}
> -------------------------------------------------------------------------------
> Test set: com.tracetracker.gqi3.QueryRestTestIntegration
> -------------------------------------------------------------------------------
> Tests run: 17, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 7.546 sec 
> <<< FAILURE!
> testSimpleEventQueryRecordTime(com.tracetracker.gqi3.QueryRestTestIntegration)
>   Time elapsed: 0.031 sec  <<< FAILURE!
> junit.framework.AssertionFailedError: List of recordTime should not be empty
>         at junit.framework.Assert.fail(Assert.java:47)
>         at junit.framework.Assert.assertTrue(Assert.java:20)
>         at 
> com.tracetracker.gqi3.QueryRestTestIntegration.testSimpleEventQueryRecordTime(QueryRestTestIntegration.java:283)
> {noformat}
> Each failing test should have the timestamp added to the start of the line.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to