00001 <?php
00002
00003
00004
00005
00006
00007
00008 class DAOStudentsTest2CoursesTest extends DataObjectBase {
00009 public $id_student;
00010 public $id_course;
00011
00012 protected function create_table_object() {
00013 return new DBTable(
00014 'studentstest2coursestest',
00015 array(
00016 new DBFieldInt('id_student', null, DBFieldInt::UNSIGNED | DBFieldInt::NOT_NULL),
00017 new DBFieldInt('id_course', null, DBFieldInt::UNSIGNED | DBFieldInt::NOT_NULL),
00018 ),
00019 array('id_student', 'id_course'),
00020 array(
00021 new DBRelation(
00022 'studentstest',
00023 new DBFieldRelation('id_student', 'id')
00024 ),
00025 new DBRelation(
00026 'coursestest',
00027 new DBFieldRelation('id_course', 'id')
00028 )
00029 ),
00030 null,
00031 new DBDriverMySqlMock()
00032 );
00033 }
00034 }