getValidated() public method

Since: 2.0
public getValidated ( ) : string[]
return string[]
Exemplo n.º 1
0
 public function testMerge()
 {
     $result1 = new Result();
     $result1->setResult(false);
     $result1->setError('foo', 'foo failed', 'foocheck');
     $result1->setValidated('bar');
     $result2 = new Result();
     $result2->setResult(true);
     $result2->setError('baz', 'baz failed', 'bazcheck');
     $result2->setValidated('bat');
     $result1->merge($result2, 'sub.');
     $this->assertEquals(['foo' => 'foo failed', 'sub.baz' => 'baz failed'], $result1->getErrors());
     $this->assertEquals(['foo' => 'foocheck', 'sub.baz' => 'bazcheck'], $result1->getFailedRules());
     $this->assertEquals(['bar', 'sub.bat'], $result1->getValidated());
 }
Exemplo n.º 2
0
 public function testSetGetValidated()
 {
     $this->object->setValidated('test');
     $this->assertEquals(array('test'), $this->object->getValidated());
 }