| 123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- package com.zipcoder.payment;
-
- import org.junit.Assert;
- import org.junit.Before;
- import org.junit.Test;
-
- public class PayPalTest {
- PayPal testPal;
-
-
- @Before
- public void initialization() {
- testPal = new PayPal(15,"Momo Hashimoto", "kawaii54@line.com");
-
- }
- @Test
- public void getSetIdTest() {
- long expected = 100;
- testPal.setId(100);
- long actual = testPal.getId();
-
- Assert.assertEquals(expected, actual);
-
- }
-
- @Test
- public void getSetPayerNameTest() {
- String expected = "Sara";
- testPal.setPayerName("Sara");
-
- String actual = testPal.getPayerName();
-
- Assert.assertEquals(expected, actual);
- }
-
- @Test
- public void getSetEmail() {
- String expected = "godot@gmail.com";
- testPal.setEmail("godot@gmail.com");
-
- String actual = testPal.getEmail();
-
- Assert.assertEquals(expected, actual);
- }
- }
|