Pheasant\Tests\FindingTestCase::testHydrateEventAfterFind PHP Method

testHydrateEventAfterFind() public method

Test find events
    public function testHydrateEventAfterFind()
    {
        $events = array();
        $this->pheasant->schema('\\Pheasant\\Tests\\Examples\\User')->events()->register('*', function ($e, $obj) use(&$events) {
            $events[] = $e;
        });
        $cletus = User::one('lastname = ?', array('Llamas', 'Kasady'));
        $this->assertEquals(array('afterHydrate'), $events);
    }