The pull request is now https://github.com/jenkinsci/jenkins/pull/916.

Am Freitag, 23. August 2013 15:41:15 UTC+2 schrieb Stefan Wolf:
>
> Hi,
>
> after trying to use the feature "Aggregate Downstream Test Results", i.e. 
> the AggregatedTestResultPublisher, I ran into some problems. The main 
> problem is fixed by my pull request 
> https://github.com/jenkinsci/jenkins/pull/915, namely that clicking the 
> "Latest Test Result" link on the Project page does not return a 404 
> anymore. I tried to document the current behaviour of the feature with a 
> "Unit" test: 
> https://github.com/wolfs/jenkins/blob/aggregate-test-result/test/src/test/java/hudson/tasks/test/AggregatedTestResultPublisherTest.java
> .
> When merging this pull request the behaviour is:
> 1. Only aggregated test results:
> - On the project page there is a link with name "Latest Test Result" which 
> goes to the aggregated test result page on the corresponding build
> 2. Only test results:
> - On the project page there is a link with name "Latest Test Result" which 
> goes to the test result page of the corresponding build
> 3. Aggregated test results and test results
> - On the project page there is a link with name "Latest Test Result" which 
> goes to the test result page of the corresponding build
>
> Moreover, there is not test result trend for the aggregated test result 
> action.
> My proposal how to make this consistent would be:
> - If the link on the project page goes to the aggregated test result page 
> then it should be named "Latest Aggregated Test Result"
> - If there are test results and aggregated test results then there should 
> be two links, one name "Latest Test Result" and one named "Latest 
> Aggregated Test Result"
> - There should be a Trend for the aggregated test results on the project 
> page
>
> If there are no objections, then I would go forward implementing this.
>
> For the implementation I would like to get some suggestions:
> - Would it make sense if the TestResult from the 
> AggregatedTestResultPublisher would extend AggregatedTestResult?
> - In the current implementation there is a method 
> 'getAggregatedTestResultAction' on the AbstractBuild class which never 
> yields the TestResult of the AggregatedTestResultPublisher. The 
> AggregatedTestResultAction yielded from this method has the urlName 
> 'testResult'. The TestResultAction of the AggregatedTestResultPublisher is 
> not an AggregatedTestResultAction and has the urlName 
> 'aggregatedTestResult'. Therefore, the old implementation on main.jelly on 
> AbstractProject did not really make sense to me:
>   <j:set var="tr" value="${it.lastCompletedBuild.testResultAction}"/>
>     <j:if test="${tr!=null}">
>       <j:if test="${tr.class.name != 
> 'hudson.tasks.test.AggregatedTestResultAction'}">
>         <t:summary icon="clipboard.png">
>           <a href="lastCompletedBuild/testResult/" class="model-link 
> inside">${%Latest Test Result}</a>
>           <t:test-result it="${tr}" />
>         </t:summary>
>       </j:if>
>     </j:if>
>
>     <j:set var="atr" 
> value="${it.lastCompletedBuild.aggregatedTestResultAction}"/>
>     <j:if test="${atr!=null}">
>       <t:summary icon="clipboard.png">
>         <a href="lastCompletedBuild/aggregatedTestReport/" 
> class="model-link inside">${%Latest Aggregated Test Result}</a>
>         <t:test-result it="${atr}" />
>       </t:summary>
>     </j:if>
> Should the UI use getAction with the corresponding classes?
> - This main.jelly should not be used from any of the classes using the 
> AggregatedTestResultAction (MavenModuleSet, MatrixProject). Is this 
> correct? So can I just change the jelly file without breaking anything?
> - What do I have to do in order to add the Trend Report for the aggregated 
> test result to the project page?
>
> Thank you for reading to the end,
> Stefan
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to