/** * @rebuild false */ public function testCollection() { $author = new Author(); $collection = $author->asCollection(); ok($collection); isa_ok('\\AuthorBooks\\Model\\AuthorCollection', $collection); }
public function testCollection() { $author = new Author(); $this->assertResultSuccess($author->create(array('name' => 'FooBar', 'email' => 'a@a', 'identity' => 'a', 'confirmed' => false))); $collection = $author->asCollection(); $this->assertNotNull($collection); $this->assertInstanceOf('LazyRecord\\BaseCollection', $collection); $this->assertResultSuccess($author->delete()); }