Advertisement
Guest User

HallTest

a guest
Feb 25th, 2020
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 6.94 KB | None | 0 0
  1. /*
  2.  * To change this license header, choose License Headers in Project Properties.
  3.  * To change this template file, choose Tools | Templates
  4.  * and open the template in the editor.
  5.  */
  6. package oosd2;
  7.  
  8. import java.util.ArrayList;
  9. import org.junit.After;
  10. import org.junit.AfterClass;
  11. import org.junit.Before;
  12. import org.junit.BeforeClass;
  13. import org.junit.Test;
  14. import static org.junit.Assert.*;
  15.  
  16. /**
  17.  *
  18.  * @author Marken Tuan Nguyen
  19.  */
  20. public class HallTest {
  21.    
  22.     public HallTest() {
  23.     }
  24.    
  25.     @BeforeClass
  26.     public static void setUpClass() {
  27.     }
  28.    
  29.     @AfterClass
  30.     public static void tearDownClass() {
  31.     }
  32.    
  33.     @Before
  34.     public void setUp() {
  35.     }
  36.    
  37.     @After
  38.     public void tearDown() {
  39.     }
  40.  
  41.     /**
  42.      * Test of getHallName method, of class Hall.
  43.      */
  44.     @Test
  45.     public void testGetHallName() {
  46.         System.out.println("getHallName");
  47.         Hall instance = new Hall();
  48.         instance.setHallName("StuVil");
  49.         String expResult = "StuVil";
  50.         String result = instance.getHallName();
  51.         assertEquals(expResult, result);
  52.         // TODO review the generated test code and remove the default call to fail.
  53.         //fail("The test case is a prototype.");
  54.     }
  55.  
  56.     /**
  57.      * Test of setHallName method, of class Hall.
  58.      */
  59.     @Test
  60.     public void testSetHallName() {
  61.         System.out.println("setHallName");
  62.         String name = "";
  63.         Hall instance = new Hall();
  64.         instance.setHallName(name);
  65.         // TODO review the generated test code and remove the default call to fail.
  66.         //fail("The test case is a prototype.");
  67.     }
  68.  
  69.     /**
  70.      * Test of getHallNumber method, of class Hall.
  71.      */
  72.     @Test
  73.     public void testGetHallNumber() {
  74.         System.out.println("getHallNumber");
  75.         Hall instance = new Hall();
  76.         int expResult = 0;
  77.         int result = instance.getHallNumber();
  78.         assertEquals(expResult, result);
  79.         // TODO review the generated test code and remove the default call to fail.
  80.         //fail("The test case is a prototype.");
  81.     }
  82.  
  83.     /**
  84.      * Test of setHallNumber method, of class Hall.
  85.      */
  86.     @Test
  87.     public void testSetHallNumber() {
  88.         System.out.println("setHallNumber");
  89.         int number = 0;
  90.         Hall instance = new Hall();
  91.         instance.setHallNumber(number);
  92.         // TODO review the generated test code and remove the default call to fail.
  93.         //fail("The test case is a prototype.");
  94.     }
  95.  
  96.     /**
  97.      * Test of getHallPhone method, of class Hall.
  98.      */
  99.     @Test
  100.     public void testGetHallPhone() {
  101.         System.out.println("getHallPhone");
  102.         Hall instance = new Hall();
  103.         int expResult = 0;
  104.         int result = instance.getHallPhone();
  105.         assertEquals(expResult, result);
  106.         // TODO review the generated test code and remove the default call to fail.
  107.         //fail("The test case is a prototype.");
  108.     }
  109.  
  110.     /**
  111.      * Test of setHallPhone method, of class Hall.
  112.      */
  113.     @Test
  114.     public void testSetHallPhone() {
  115.         System.out.println("setHallPhone");
  116.         int hallPhone = 0;
  117.         Hall instance = new Hall();
  118.         instance.setHallPhone(hallPhone);
  119.         // TODO review the generated test code and remove the default call to fail.
  120.         //fail("The test case is a prototype.");
  121.     }
  122.  
  123.     /**
  124.      * Test of getHallAddress method, of class Hall.
  125.      */
  126.     @Test
  127.     public void testGetHallAddress() {
  128.         System.out.println("getHallAddress");
  129.         Hall instance = new Hall();
  130.         instance.setHallAddress("UWE");
  131.         String expResult = "UWE";
  132.         String result = instance.getHallAddress();
  133.         assertEquals(expResult, result);
  134.         // TODO review the generated test code and remove the default call to fail.
  135.         //fail("The test case is a prototype.");
  136.     }
  137.  
  138.     /**
  139.      * Test of setHallAddress method, of class Hall.
  140.      */
  141.     @Test
  142.     public void testSetHallAddress() {
  143.         System.out.println("setHallAddress");
  144.         String address = "";
  145.         Hall instance = new Hall();
  146.         instance.setHallAddress(address);
  147.         // TODO review the generated test code and remove the default call to fail.
  148.         //fail("The test case is a prototype.");
  149.     }
  150.  
  151.     /**
  152.      * Test of getHallPhoneNumb method, of class Hall.
  153.      */
  154.     @Test
  155.     public void testGetHallPhoneNumb() {
  156.         System.out.println("getHallPhoneNumb");
  157.         Hall instance = new Hall();
  158.         instance.setHallPhoneNumb("123234");
  159.         String expResult = "123234";
  160.         String result = instance.getHallPhoneNumb();
  161.         assertEquals(expResult, result);
  162.         // TODO review the generated test code and remove the default call to fail.
  163.         //fail("The test case is a prototype.");
  164.     }
  165.  
  166.     /**
  167.      * Test of setHallPhoneNumb method, of class Hall.
  168.      */
  169.     @Test
  170.     public void testSetHallPhoneNumb() {
  171.         System.out.println("setHallPhoneNumb");
  172.         String phoneNumb = "";
  173.         Hall instance = new Hall();
  174.         instance.setHallPhoneNumb(phoneNumb);
  175.         // TODO review the generated test code and remove the default call to fail.
  176.         //fail("The test case is a prototype.");
  177.     }
  178.  
  179.     /**
  180.      * Test of getRooms method, of class Hall.
  181.      */
  182.     @Test
  183.     public void testGetRooms() {
  184.         System.out.println("getRooms");
  185.         Hall instance = new Hall();
  186.         ArrayList<Room> expResult = null;
  187.         ArrayList<Room> result = instance.getRooms();
  188.         assertEquals(expResult, result);
  189.         // TODO review the generated test code and remove the default call to fail.
  190.         //fail("The test case is a prototype.");
  191.     }
  192.  
  193.     /**
  194.      * Test of setRooms method, of class Hall.
  195.      */
  196.     @Test
  197.     public void testSetRooms() {
  198.         System.out.println("setRooms");
  199.         ArrayList<Room> rooms = null;
  200.         Hall instance = new Hall();
  201.         instance.setRooms(rooms);
  202.         // TODO review the generated test code and remove the default call to fail.
  203.         //fail("The test case is a prototype.");
  204.     }
  205.  
  206.     /**
  207.      * Test of addRoom method, of class Hall.
  208.      */
  209.     @Test
  210.     public void testAddRoom() {
  211.         System.out.println("addRoom");
  212.         Room room = new Room(123,321,0);
  213.         Hall instance = new Hall("uwe111", 111);
  214.         instance.addRoom(room);
  215.         // TODO review the generated test code and remove the default call to fail.
  216.         //fail("The test case is a prototype.");
  217.     }
  218.  
  219.     /**
  220.      * Test of removeRoom method, of class Hall.
  221.      */
  222.     @Test
  223.     public void testRemoveRoom() {
  224.         System.out.println("removeRoom");
  225.         Room room = new Room(123,321,0);
  226.         Hall instance = new Hall("uwe111", 111);
  227.        
  228.         instance.removeRoom(room);
  229.         // TODO review the generated test code and remove the default call to fail.
  230.         //fail("The test case is a prototype.");
  231.     }
  232.    
  233. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement