public function testRules() { $this->assertNull($this->object->post->age(null, 'ctype_digit')); $this->assertEquals(0, $this->object->post->age(0, 'ctype_digit')); $this->assertEquals($this->post['age'], $this->object->post->age()); $this->assertEquals(0, $this->object->age(0, 'ctype_digit')); $this->assertEquals($this->post['age'], $this->object->post->age(10), '/^\\d/'); }