站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBOSS Portal 2.6 API 英文版文档

AssertResult - JBOSS Portal 2.6 API 英文版文档


org.jboss.portal.test.framework.container.result
Class AssertResult

java.lang.Object
  extended byorg.jboss.portal.test.framework.container.result.Result
      extended byorg.jboss.portal.test.framework.container.result.AssertResult
All Implemented Interfaces:
java.io.Serializable

public class AssertResult
extends Result

A set of assertions as result.

Version:
$Revision: 5498 $
Author:
Julien Viet
See Also:
Serialized Form

Nested Class Summary
static class AssertResult.Test
           
 
Field Summary
private static org.apache.log4j.Logger log
          .
private static long serialVersionUID
          The serialVersionUID
private  java.lang.Throwable throwable
          The throwable that failed this assertion.
 
Constructor Summary
AssertResult()
           
AssertResult(java.lang.Throwable t)
           
 
Method Summary
 ClientCommand createCommand()
          Return the command to execute on the client side.
 void execute(AssertResult.Test test)
          Run the test, record the error or failure if any and increment the count.
 java.lang.Throwable getThrowable()
          Return the recorded throwable or null if nothing has been recorded.
 boolean isFailed()
          Return true if throwable is null.
static AssertResult run(AssertResult.Test test)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
The serialVersionUID

See Also:
Constant Field Values

log

private static org.apache.log4j.Logger log
.


throwable

private java.lang.Throwable throwable
The throwable that failed this assertion.

Constructor Detail

AssertResult

public AssertResult()

AssertResult

public AssertResult(java.lang.Throwable t)
Method Detail

run

public static AssertResult run(AssertResult.Test test)
                        throws java.lang.IllegalArgumentException,
                               java.lang.IllegalStateException
Throws:
java.lang.IllegalArgumentException
java.lang.IllegalStateException

execute

public void execute(AssertResult.Test test)
             throws java.lang.IllegalArgumentException,
                    java.lang.IllegalStateException
Run the test, record the error or failure if any and increment the count.

Parameters:
test - the test to execute
Throws:
java.lang.IllegalArgumentException - if test is null
java.lang.IllegalStateException - if the test is already failed

getThrowable

public java.lang.Throwable getThrowable()
Return the recorded throwable or null if nothing has been recorded.


isFailed

public boolean isFailed()
Return true if throwable is null.


createCommand

public ClientCommand createCommand()
Description copied from class: Result
Return the command to execute on the client side.

Specified by:
createCommand in class Result