Skip to content

Commit

Permalink
Add doc for RecordManagerTest
Browse files Browse the repository at this point in the history
  • Loading branch information
lschaefer-sugarcrm committed Feb 8, 2018
1 parent b5258e7 commit 0ad5ac6
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions tests/phpunit/src/custom/gradebook_fake/RecordManagerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,24 @@
use Sugarcrm\Sugarcrm\custom\gradebook_fake\RecordManager;
use PHPUnit\Framework\TestCase;

/**
* Class RecordManagerTest
* Tests the RecordManager for the GradebookFake app
*/
class RecordManagerTest extends TestCase
{
/**
* Check that when valid params are sent to createStudentRecord, true is returned
*/
public function testRecordManagerValidParams(){
$rm = new RecordManager();
$this->assertTrue($rm->createStudentRecord('[email protected]', 'Lauren', 'Sample'));
}

/**
* Check that when the email address [email protected] is used as a param for createStudentRecord, an
* exception is thrown
*/
public function testRecordManagerForceException(){
$rm = new RecordManager();
$this -> expectException(Exception::class);
Expand Down

0 comments on commit 0ad5ac6

Please sign in to comment.