hudson.plugins.testng.results
Class BaseResult

java.lang.Object
  extended by hudson.model.AbstractModelObject
      extended by hudson.tasks.junit.TestObject
          extended by hudson.tasks.test.TestObject
              extended by hudson.tasks.test.TestResult
                  extended by hudson.tasks.test.TabulatedResult
                      extended by hudson.plugins.testng.results.BaseResult
All Implemented Interfaces:
hudson.model.ModelObject, hudson.search.SearchableModelObject, hudson.search.SearchItem, Serializable
Direct Known Subclasses:
ClassResult, MethodResult, PackageResult, TestNGResult

@ExportedBean
public abstract class BaseResult
extends hudson.tasks.test.TabulatedResult
implements hudson.model.ModelObject, Serializable

Base class that takes care of all the common functionality of the different kinds of test results.

See Also:
Serialized Form

Field Summary
protected  String name
           
protected  hudson.model.AbstractBuild<?,?> owner
           
protected  BaseResult parent
           
 
Constructor Summary
BaseResult(String name)
           
 
Method Summary
 hudson.tasks.test.TestResult findCorrespondingResult(String id)
           
 long getAge()
          Gets the age of a result
 String getDisplayName()
           
 Object getDynamic(String token, org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp)
           
 String getName()
           
 hudson.model.AbstractBuild<?,?> getOwner()
           
 BaseResult getParent()
           
 hudson.tasks.test.AbstractTestResultAction getParentAction()
           
 hudson.tasks.test.AbstractTestResultAction getTestResultAction()
          Explicit override here to ensure that when we are building TestNG reports, we are only working with TestNG results (and not results from other test reporters).
 String getTitle()
           
 String getUpUrl()
           
 void setOwner(hudson.model.AbstractBuild<?,?> owner)
           
 void setParent(BaseResult parent)
           
 
Methods inherited from class hudson.tasks.test.TabulatedResult
getChildren, getChildTitle, hasChildren
 
Methods inherited from class hudson.tasks.test.TestResult
annotate, getBuildResult, getDuration, getErrorDetails, getErrorStackTrace, getFailCount, getFailedSince, getFailedSinceRun, getFailedTests, getPassCount, getPassedTests, getPreviousResult, getResultInBuild, getSkipCount, getSkippedTests, getStderr, getStdout, isPassed, setParent, setParentAction, tally, toPrettyString
 
Methods inherited from class hudson.tasks.test.TestObject
doSubmitDescription, getApi, getDescription, getDurationString, getHistory, getId, getRelativePathFrom, getSafeName, getSearchUrl, getTestAction, getTestActions, getTestResult, getTopLevelTestResult, getTotalCount, getUrl, safe, setDescription, uniquifyName
 
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
 

Field Detail

owner

protected hudson.model.AbstractBuild<?,?> owner

name

protected final String name

parent

protected BaseResult parent
Constructor Detail

BaseResult

public BaseResult(String name)
Method Detail

getName

@Exported(visibility=999)
public String getName()
Overrides:
getName in class hudson.tasks.test.TestObject

getParent

public BaseResult getParent()
Overrides:
getParent in class hudson.tasks.test.TestObject

setParent

public void setParent(BaseResult parent)

getOwner

public hudson.model.AbstractBuild<?,?> getOwner()
Specified by:
getOwner in class hudson.tasks.test.TestObject

setOwner

public void setOwner(hudson.model.AbstractBuild<?,?> owner)

getTitle

public String getTitle()
Overrides:
getTitle in class hudson.tasks.test.TestResult

getDisplayName

public String getDisplayName()
Specified by:
getDisplayName in interface hudson.model.ModelObject

getUpUrl

public String getUpUrl()

getDynamic

public Object getDynamic(String token,
                         org.kohsuke.stapler.StaplerRequest req,
                         org.kohsuke.stapler.StaplerResponse rsp)
Overrides:
getDynamic in class hudson.tasks.test.TestObject

getTestResultAction

public hudson.tasks.test.AbstractTestResultAction getTestResultAction()
Explicit override here to ensure that when we are building TestNG reports, we are only working with TestNG results (and not results from other test reporters). Can get into a bad situation if the same job has configured JUnit and TestNG reports

Overrides:
getTestResultAction in class hudson.tasks.test.TestObject
Returns:

getParentAction

public hudson.tasks.test.AbstractTestResultAction getParentAction()
Overrides:
getParentAction in class hudson.tasks.test.TestResult
Returns:
See Also:
getTestResultAction()

findCorrespondingResult

public hudson.tasks.test.TestResult findCorrespondingResult(String id)
Specified by:
findCorrespondingResult in class hudson.tasks.test.TestObject

getAge

public long getAge()
Gets the age of a result

Returns:
the number of consecutive builds for which we have a result for this package


Copyright © 2004-2013. All Rights Reserved.