org.unitils.mock.dummy
Class DummyObjectUtil
java.lang.Object
org.unitils.mock.dummy.DummyObjectUtil
public class DummyObjectUtil
- extends Object
Class for handling the dummy object behavior. A dummy object is a proxy that will return default values for every method. This can be
used to quickly create test objects without having to worry about correctly filling in every field.
- Author:
- Filip Neven, Tim Ducheyne
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DummyObjectUtil
public DummyObjectUtil()
createDummy
public static <T> T createDummy(Class<T> type)
- Creates the dummy proxy object.
- Parameters:
type
- The type for the proxy, not null
- Returns:
- The proxy, not null
createDummy
public static <T> T createDummy(Class<T> type,
MockBehavior mockBehaviour)
Copyright © 2011. All Rights Reserved.