dtu.library.app
Class SampleDataSetup

java.lang.Object
  extended by dtu.library.app.SampleDataSetup
Direct Known Subclasses:
TestBorrowBook, TestDateServer, TestOverdue, TestReturnBook, TestSearchBook

public class SampleDataSetup
extends java.lang.Object

A class the defines a common setUp (e.g. a method with the @Before Annotation) containing sample data.

Test classes that want to use that data should inherit from this class.

Author:
hub

Constructor Summary
SampleDataSetup()
           
 
Method Summary
 void setUp()
          Create the sample data for the search test cases.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SampleDataSetup

public SampleDataSetup()
Method Detail

setUp

public void setUp()
           throws java.lang.Exception
Create the sample data for the search test cases. This method is executed each time one of the test methods is run. In contrast to old JUnit versions, it is now the @Before annotations that marks this method to be run before each test case and not the name setUp(). This method is inherited by subclasses. Thus any tests that needs sample data, should inherit from this class and add sample data as necessary.

Throws:
java.lang.Exception