예제 #1
0
파일: Form.php 프로젝트: aleguisf/fvdev1
 /**
  * Populate a form with specific values
  *
  * @param array|object $values
  *
  * @return $this
  */
 public function populate($values)
 {
     $this->populator->replace($values);
     return $this;
 }
예제 #2
0
 public function testCanSwapOutValues()
 {
     $populator = new Populator(array('foo', 'bar'));
     $populator->replace(array('bar', 'foo'));
     $this->assertEquals(array('bar', 'foo'), $populator->all());
 }