$hotelType = ""; $Hname = $_POST['textbox_Hotel_name']; $gameID = $_POST['textbox_Hotel_game_id']; if (isset($_POST['hotelLocation'])) { $location = $_POST['hotelLocation']; } if (isset($_POST['hotelType'])) { $hotelType = $_POST['hotelType']; } $fname = $_POST['textbox_bot_fname']; $lname = $_POST['textbox_bot_lname']; $email = $_POST['textbox_bot_email']; $value = $adminController->addBot($Hname, $gameID, $location, $hotelType, $fname, $lname, $email); } else { if (isset($_POST['button_createGamePage'])) { $value = $adminController->createGamePage(); } else { if (isset($_POST['button_addGame'])) { $courseNumber = $_POST['textbox_courseNumber']; $courseID = $_POST['textbox_courseID']; $section = $_POST['textbox_section']; $semester = $_POST['textbox_semester']; $schedule = $_POST['textbox_schedule']; $value = $adminController->createGame($semester, $courseID, $courseNumber, $section, $schedule); } else { if (isset($_POST['button_activate'])) { if (isset($_POST['tableCheckbox'])) { $value = $adminController->activateUsers($_POST['tableCheckbox']); } else { $value = "No Users Selected"; }
/** * @covers a */ function test_createGamePage() { $a = new AdminController(); $result = "<div class='' align='left'>" . "<h2>Game Creation Page</h2>" . "<h3>Course Number</h3>" . "<input type = 'text' name = 'textbox_courseNumber' pattern='[0-9]{5}' placeholder = '88529' title='5 digit number'>" . "<h3>Course ID</h3>" . "<input type = 'text' name = 'textbox_courseID' placeholder = 'MAR2015'>" . "<h3>Section</h3>" . "<input type = 'text' name = 'textbox_section' placeholder='U02'>" . "<h3>Semester of Game</h3>" . "<input type = 'text' name = 'textbox_semester' placeholder='FALL 2016'>" . "<h3>Course Meeting time</h3>" . "<input type = 'text' name = 'textbox_schedule' placeholder='mwf 12pm-1:30pm'>" . "<br />" . "<br />" . "<br />" . "<input name='button_addGame' type = 'submit' value = 'Create Game' class='btn btn-primary'/>" . "</div>"; return $this->assertEquals($a->createGamePage(), $result); }