GitBucket
4.21.2
Toggle navigation
Snippets
Sign in
Files
Branches
1
Releases
Issues
Pull requests
Labels
Priorities
Milestones
Wiki
Forks
nigel.stanger
/
sqlmarker
Browse code
Added legal values test.
master
1 parent
3651356
commit
7873d87084ae0f9a311e6281736b5085610d1139
Nigel Stanger
authored
on 30 Aug 2013
Patch
Showing
1 changed file
STINK_student_records/Test_classes/Enrolment/STINK_student_records_Test_Enrolment_data.php
Ignore Space
Show notes
View
STINK_student_records/Test_classes/Enrolment/STINK_student_records_Test_Enrolment_data.php
<?php require_once "Enrolment/STINK_student_records_Test_Enrolment.php"; /** * @backupGlobals disabled * @backupStaticAttributes disabled */ class STINK_student_records_Test_Enrolment_data extends STINK_student_records_Test_Enrolment { /** * Return fixture data set for current database connection. * * @access protected * @return PHPUnit_Extensions_Database_DataSet_IDataSet * @todo Parameterise the fixture filename. */ protected function getDataSet() { return $this->createXMLDataSet( TEST_CLASS_PATH . '/Enrolment/STINK_student_records_Fixture_Enrolment.xml' ); } /** * @dataProvider provideColumnUnderflowValues * @expectedException PDOException * @expectedExceptionMessage check constraint * @expectedExceptionCode HY000 */ public function testColumnUnderflowValue( $columnName, $underflowValue ) { $this->assertColumnUnderflowValue( $columnName, $underflowValue ); } /** * @dataProvider provideColumnLegalValues */ public function testColumnLegalValue( $columnName, $legalValue ) { $this->assertColumnLegalValue( $columnName, $legalValue ); } } ?>
<?php require_once "Enrolment/STINK_student_records_Test_Enrolment.php"; /** * @backupGlobals disabled * @backupStaticAttributes disabled */ class STINK_student_records_Test_Enrolment_data extends STINK_student_records_Test_Enrolment { /** * Return fixture data set for current database connection. * * @access protected * @return PHPUnit_Extensions_Database_DataSet_IDataSet * @todo Parameterise the fixture filename. */ protected function getDataSet() { return $this->createXMLDataSet( TEST_CLASS_PATH . '/Enrolment/STINK_student_records_Fixture_Enrolment.xml' ); } /** * @dataProvider provideColumnUnderflowValues * @expectedException PDOException * @expectedExceptionMessage check constraint * @expectedExceptionCode HY000 */ public function testColumnUnderflowValue( $columnName, $underflowValue ) { $this->assertColumnUnderflowValue( $columnName, $underflowValue ); } } ?>
Show line notes below