| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849 |
- import static org.junit.Assert.*;
- import org.junit.After;
- import org.junit.Before;
- import org.junit.Test;
-
- /**
- * The test class DepositAccountTest.
- *
- * @author (your name)
- * @version (a version number or a date)
- */
- public class DepositAccountTest
- {
- /**
- * Default constructor for test class DepositAccountTest
- */
- public DepositAccountTest()
- {
- }
-
- @Test
- public void constructorTest() {
- DepositAccount depositAccount = new DepositAccount(5, 1.5);
- int expectedBalance = 5;
- int actualBalance = depositAccount.balance();
- assertEquals(expectedBalance, actualBalance);
- }
-
- /**
- * Sets up the test fixture.
- *
- * Called before every test case method.
- */
- @Before
- public void setUp()
- {
- }
-
- /**
- * Tears down the test fixture.
- *
- * Called after every test case method.
- */
- @After
- public void tearDown()
- {
- }
- }
|