public function setUp() { require_once dirname(__DIR__) . '/Db/table/DewdropTestFruits.php'; $this->inputFilter = new InputFilter(); $db = new MockAdapter(); $table = new \DewdropTest\DewdropTestFruits($db); $this->fields = new Edit($this->inputFilter); $this->row = $table->createRow(); }
/** * @expectedException \Dewdrop\Exception */ public function testUsingDifferentModelsWithTheSameNameThrowsException() { require_once __DIR__ . '/Db/table/DewdropTestFruits.php'; $fruits = new \DewdropTest\DewdropTestFruits(); require_once __DIR__ . '/Db/table/DewdropTestAnimals.php'; $animals = new \DewdropTest\DewdropTestAnimals(); $this->fields->add($fruits->field('name'), 'duplicate')->add($animals->field('name'), 'duplicate'); }