+ $constraint = new Choice(array('callback' => 'staticCallback', 'strict' => true));
+
+ $this->validator->validate('bar', $constraint);
+
+ $this->assertNoViolation();
+ }
+
+ public function testValidChoiceCallbackContextObjectMethod()
+ {
+ // search $this for "objectMethodCallback"
+ $this->setObject($this);
+
+ $constraint = new Choice(array('callback' => 'objectMethodCallback', 'strict' => true));