net.grinder.testutility
Class RandomStubFactory<T>

java.lang.Object
  extended by junit.framework.Assert
      extended by net.grinder.testutility.CallRecorder
          extended by net.grinder.testutility.AbstractStubFactory<T>
              extended by net.grinder.testutility.RandomStubFactory<T>
All Implemented Interfaces:
CallAssertions

public class RandomStubFactory<T>
extends AbstractStubFactory<T>

AbstractStubFactory that takes a Class and generates stubs that support all the interface of the given class and have methods that return random primitive results and null objects for complex results.

Author:
Philip Aston

Nested Class Summary
 
Nested classes/interfaces inherited from class net.grinder.testutility.CallRecorder
CallRecorder.MethodFilter
 
Constructor Summary
protected RandomStubFactory(Class<T> stubbedInterface)
           
 
Method Summary
static
<T> RandomStubFactory<T>
create(Class<T> stubbedInterface)
           
 
Methods inherited from class net.grinder.testutility.AbstractStubFactory
getAllInterfaces, getClass, getFactory, getStub, setResult, setThrows
 
Methods inherited from class net.grinder.testutility.CallRecorder
assertException, assertException, assertException, assertException, assertNoMoreCalls, assertSuccess, assertSuccess, getCallHistory, peekFirst, record, resetCallHistory, setIgnoreCallOrder, setIgnoreMethod, setIgnoreObjectMethods, waitUntilCalled
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame, format
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RandomStubFactory

protected RandomStubFactory(Class<T> stubbedInterface)
Method Detail

create

public static <T> RandomStubFactory<T> create(Class<T> stubbedInterface)


Copyright © 2000-2012. All Rights Reserved.