Class RemoteTestCase

java.lang.Object
edu.pdx.cs.joy.family.RemoteTestCase
Direct Known Subclasses:
RemoteFamilyTreeTest, RemotePersonTest

public abstract class RemoteTestCase extends Object
This is the abstract superclass for all of the remote family tree tests.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    Asserts the equality of two dates.
    protected void
    Convenience method that binds a given RemoteFamilyTree into the RMI namespace.
    static void
    fail(String message, Throwable cause)
    A JUnit failure that is caused by an exception.
    protected String
    Returns the name that the RemoteFamilyTree is bound into in the RMI namespace.
    Returns the RemoteFamilyTree used by this test
    void
    setUp(File tempDir)
    Creates an empty RemoteFamilyTree and binds it into the RMI namespace.
    void
    Unbinds the remote family tree from the RMI namespace
    protected void
    Convenience method that unbinds and shuts down the remote family tree from the RMI namespace.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • setUp

      @BeforeEach public void setUp(@TempDir File tempDir)
      Creates an empty RemoteFamilyTree and binds it into the RMI namespace.
    • tearDown

      @AfterEach public void tearDown()
      Unbinds the remote family tree from the RMI namespace
    • getFamilyName

      protected String getFamilyName()
      Returns the name that the RemoteFamilyTree is bound into in the RMI namespace.
    • getTree

      Returns the RemoteFamilyTree used by this test
    • bind

      protected void bind(RemoteFamilyTree tree)
      Convenience method that binds a given RemoteFamilyTree into the RMI namespace.
    • unbind

      protected void unbind()
      Convenience method that unbinds and shuts down the remote family tree from the RMI namespace.
    • assertEquals

      protected void assertEquals(Date d1, Date d2)
      Asserts the equality of two dates. Only takes the month, day, and year into account.
    • fail

      public static void fail(String message, Throwable cause)
      A JUnit failure that is caused by an exception. This method provides us with a nice strack trace for the failure.
      Since:
      Winter 2004