public function setUp() { parent::setUp(); foreach (self::fixtureData() as $item) { MockPersistent::create($item, $this->fixture); } }
public function setUp() { parent::setUp(); $this->fixture = $this->tacit->container->get('repository'); foreach (self::fixtureData() as $item) { MockPersistent::create($item, $this->fixture); } }
/** * Test the MockPersistent::create() method. * * @param array $data * * @dataProvider providerCreate * @group model */ public function testCreate($data) { try { $object = MockPersistent::create($data, $this->fixture); $this->assertNotNull($object); $this->assertInstanceOf('Tacit\\Model\\Persistent', $object); $this->assertInstanceOf('Tacit\\Test\\Model\\MockPersistent', $object); } catch (ModelValidationException $e) { echo $e; } }