function isValid($value)
 {
     $nameValidator = new C3op_Util_ValidInteger();
     return $nameValidator->isValid($value) && $value >= 0;
 }
Exemple #2
0
 public function testThatAStringValueIsNotValid()
 {
     $validator = new C3op_Util_ValidInteger();
     $notANumber = "one two três quatorze";
     $this->assertFalse($validator->isValid($notANumber));
 }