test.jmock.core
Class AbstractDynamicMockTest

java.lang.Object
  extended byjunit.framework.Assert
      extended byjunit.framework.TestCase
          extended bytest.jmock.core.AbstractDynamicMockTest
All Implemented Interfaces:
Test
Direct Known Subclasses:
CGLIBCoreMockTest, CoreMockTest

public abstract class AbstractDynamicMockTest
extends TestCase


Constructor Summary
AbstractDynamicMockTest()
           
 
Method Summary
protected abstract  DynamicMock createDynamicMock(String name, InvocationDispatcher dispatcher)
           
protected abstract  Class mockedType()
           
protected  DummyInterface proxy()
           
 void setUp()
           
 void testAddsInvokablesToDispatcher()
           
 void testCalculatesHashCodeForProxy()
           
 void testCanOverrideEqualsForProxyBySettingAStub()
           
 void testCanOverrideHashCodeForProxyBySettingAStub()
           
 void testExceptionsPropagatedThroughProxy()
           
 void testExposesDefaultStubOfDispatcher()
           
 void testGeneratesMockNameFromInterfaceNameIfNoNameSpecified()
           
 void testMockAnnotatesAssertionFailedError()
           
 void testMockVerifies()
           
 void testProxyReturnsConfiguredResult()
           
 void testReportsMockedType()
           
 void testResetsDispatcher()
           
 void testReturnsNameFromToString()
           
 void testTestsEqualityForProxy()
           
 void testVerifyFailuresIncludeMockName()
           
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, tearDown, toString
 
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
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AbstractDynamicMockTest

public AbstractDynamicMockTest()
Method Detail

setUp

public void setUp()

createDynamicMock

protected abstract DynamicMock createDynamicMock(String name,
                                                 InvocationDispatcher dispatcher)

mockedType

protected abstract Class mockedType()

proxy

protected DummyInterface proxy()

testReportsMockedType

public void testReportsMockedType()

testMockAnnotatesAssertionFailedError

public void testMockAnnotatesAssertionFailedError()
                                           throws Throwable
Throws:
Throwable

testProxyReturnsConfiguredResult

public void testProxyReturnsConfiguredResult()
                                      throws Throwable
Throws:
Throwable

testExceptionsPropagatedThroughProxy

public void testExceptionsPropagatedThroughProxy()
                                          throws Throwable
Throws:
Throwable

testMockVerifies

public void testMockVerifies()
                      throws Exception
Throws:
Exception

testTestsEqualityForProxy

public void testTestsEqualityForProxy()
                               throws Exception
Throws:
Exception

testCanOverrideEqualsForProxyBySettingAStub

public void testCanOverrideEqualsForProxyBySettingAStub()
                                                 throws Exception
Throws:
Exception

testCalculatesHashCodeForProxy

public void testCalculatesHashCodeForProxy()
                                    throws Exception
Throws:
Exception

testCanOverrideHashCodeForProxyBySettingAStub

public void testCanOverrideHashCodeForProxyBySettingAStub()
                                                   throws Exception
Throws:
Exception

testGeneratesMockNameFromInterfaceNameIfNoNameSpecified

public void testGeneratesMockNameFromInterfaceNameIfNoNameSpecified()
                                                             throws Exception
Throws:
Exception

testReturnsNameFromToString

public void testReturnsNameFromToString()

testAddsInvokablesToDispatcher

public void testAddsInvokablesToDispatcher()

testExposesDefaultStubOfDispatcher

public void testExposesDefaultStubOfDispatcher()

testResetsDispatcher

public void testResetsDispatcher()

testVerifyFailuresIncludeMockName

public void testVerifyFailuresIncludeMockName()