Exemplo n.º 1
0
 public function testAttributes()
 {
     $d = new Dummy();
     $d->dum = 'dum-dum';
     $this->assertTrue($d->hasAttribute('dum'));
     $an = $d->attributeNames();
     $this->assertArrayHasKey('dum', array_flip($an));
     $d->username = '******';
     $attr = $d->getAttributes();
     $this->assertArrayHasKey('username', $attr);
     $this->assertArrayHasKey('dum', $attr);
 }