hudson.plugins.robot.model
Class RobotSuiteResult

java.lang.Object
  extended by hudson.model.AbstractModelObject
      extended by hudson.plugins.robot.model.RobotTestObject
          extended by hudson.plugins.robot.model.RobotSuiteResult
All Implemented Interfaces:
hudson.model.ModelObject, hudson.search.SearchableModelObject, hudson.search.SearchItem, java.io.Serializable

public class RobotSuiteResult
extends RobotTestObject

See Also:
Serialized Form

Constructor Summary
RobotSuiteResult()
           
 
Method Summary
 void addCaseResult(RobotCaseResult caseResult)
          Adds a test case result to this suite.
 void addCaseResults(java.util.Collection<RobotCaseResult> newCaseResults)
          If cases with same name exist, the originals are kept
 void addChild(RobotSuiteResult child)
          Adds a nested suite to this suite.
 void addChildren(java.util.Collection<RobotSuiteResult> childSuites)
          If suites with same name exist, the originals are kept
 void doDurationGraph(org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp)
          Return duration graph for the suite in the request.
 void doGraph(org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp)
          Return robot trend graph in the request.
 RobotTestObject findObjectById(java.lang.String id)
          Get object by path in tree
 java.util.List<RobotSuiteResult> getAllChildSuites()
          Get all children of this suite
 java.util.List<RobotCaseResult> getAllFailedCases()
          Get all failed cases in this suite and its child suites
 RobotCaseResult getCase(java.lang.String name)
          Get case result by safe name
 java.util.Collection<RobotCaseResult> getCaseResults()
          Get all case results belonging to this suite
 java.util.Collection<RobotSuiteResult> getChildSuites()
          Get the immediate child suites of this suite
 int getCriticalFailed()
          Get number of failed critical tests
 int getCriticalPassed()
          Get number of passed critical tests
 int getCriticalTotal()
          Get number of all critical tests
 java.lang.String getDisplayName()
           
 long getDuration()
          Get duration of this testsuite run
 java.lang.Object getDynamic(java.lang.String token, org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerRequest rsp)
          Get suite or case result by safe name
 int getFailed()
          Get number of all failed tests
 java.lang.String getName()
          Get the name of this suite
 RobotTestObject getParent()
          Get the parent object of this suite in tree
 int getPassed()
          Get number of all passed tests
 RobotSuiteResult getPreviousResult()
          
 java.lang.String getSearchUrl()
           
 RobotSuiteResult getSuite(java.lang.String name)
          Get nested suite result by safe name
 int getTotal()
          Get number of all tests
 void setName(java.lang.String name)
           
 void setParent(RobotTestObject parent)
           
 void tally(RobotBuildAction parentAction)
          Count total values from children and set same parentaction to all
 
Methods inherited from class hudson.plugins.robot.model.RobotTestObject
getOwner, getParentAction, getRelativeId, getRelativePackageName, getResultInBuild, getSafeName, isNeedToGenerate, setParentAction
 
Methods inherited from class hudson.model.AbstractModelObject
getSearch, getSearchIndex, getSearchName, makeSearchIndex, requirePOST, sendError, sendError, sendError, sendError, sendError
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RobotSuiteResult

public RobotSuiteResult()
Method Detail

addChild

public void addChild(RobotSuiteResult child)
Adds a nested suite to this suite. If a suite exists with the same name it will be overwritten with this one.

Parameters:
child -

getChildSuites

public java.util.Collection<RobotSuiteResult> getChildSuites()
Get the immediate child suites of this suite

Returns:

getParent

public RobotTestObject getParent()
Get the parent object of this suite in tree

Specified by:
getParent in class RobotTestObject

setParent

public void setParent(RobotTestObject parent)

getName

public java.lang.String getName()
Get the name of this suite

Specified by:
getName in class RobotTestObject

setName

public void setName(java.lang.String name)

getCaseResults

public java.util.Collection<RobotCaseResult> getCaseResults()
Get all case results belonging to this suite

Returns:

getFailed

public int getFailed()
Get number of all failed tests

Returns:

getPassed

public int getPassed()
Get number of all passed tests

Returns:

getTotal

public int getTotal()
Get number of all tests

Returns:

getDuration

public long getDuration()
Get duration of this testsuite run

Returns:

getCriticalPassed

public int getCriticalPassed()
Get number of passed critical tests

Returns:

getCriticalFailed

public int getCriticalFailed()
Get number of failed critical tests

Returns:

getCriticalTotal

public int getCriticalTotal()
Get number of all critical tests

Returns:

addCaseResult

public void addCaseResult(RobotCaseResult caseResult)
Adds a test case result to this suite. If a case exists with the same name it will be overwritten with this one.

Parameters:
caseResult -

getDisplayName

public java.lang.String getDisplayName()

getSearchUrl

public java.lang.String getSearchUrl()

getSuite

public RobotSuiteResult getSuite(java.lang.String name)
Get nested suite result by safe name

Parameters:
name -
Returns:
suite result, null if none found

getCase

public RobotCaseResult getCase(java.lang.String name)
Get case result by safe name

Parameters:
name -
Returns:
case result, null if none found

getPreviousResult

public RobotSuiteResult getPreviousResult()

Specified by:
getPreviousResult in class RobotTestObject

getDynamic

public java.lang.Object getDynamic(java.lang.String token,
                                   org.kohsuke.stapler.StaplerRequest req,
                                   org.kohsuke.stapler.StaplerRequest rsp)
Get suite or case result by safe name

Parameters:
token -
req -
rsp -
Returns:

getAllChildSuites

public java.util.List<RobotSuiteResult> getAllChildSuites()
Get all children of this suite

Returns:

getAllFailedCases

public java.util.List<RobotCaseResult> getAllFailedCases()
Get all failed cases in this suite and its child suites

Returns:

tally

public void tally(RobotBuildAction parentAction)
Count total values from children and set same parentaction to all

Parameters:
parentAction -

findObjectById

public RobotTestObject findObjectById(java.lang.String id)
Get object by path in tree

Parameters:
id -
Returns:

doGraph

public void doGraph(org.kohsuke.stapler.StaplerRequest req,
                    org.kohsuke.stapler.StaplerResponse rsp)
             throws java.io.IOException
Return robot trend graph in the request.

Parameters:
req -
rsp -
Throws:
java.io.IOException

doDurationGraph

public void doDurationGraph(org.kohsuke.stapler.StaplerRequest req,
                            org.kohsuke.stapler.StaplerResponse rsp)
                     throws java.io.IOException
Return duration graph for the suite in the request.

Parameters:
req -
rsp -
Throws:
java.io.IOException

addChildren

public void addChildren(java.util.Collection<RobotSuiteResult> childSuites)
If suites with same name exist, the originals are kept

Parameters:
childSuites -

addCaseResults

public void addCaseResults(java.util.Collection<RobotCaseResult> newCaseResults)
If cases with same name exist, the originals are kept

Parameters:
caseResults -


Copyright © 2004-2012. All Rights Reserved.