Example #1
0
 public function __construct(array $options = array())
 {
     $options = new Options($options);
     Options::required('name, alpha2, alpha3, numeric', $options);
     $this->name = $options['name'];
     unset($options['name']);
     foreach ($options as $k => $v) {
         $this->codes[] = new CountryCode($v);
     }
 }
 /**
  * @expectedException \InvalidArgumentException
  */
 public function testFailRecursiveRequired()
 {
     $options = new Options($this->options);
     $exists = Options::required('pass', $options->billing_address);
 }