diff --git a/tests/Fake/FakeController.php b/tests/Fake/FakeController.php index 6ed7ae2..d642e52 100644 --- a/tests/Fake/FakeController.php +++ b/tests/Fake/FakeController.php @@ -24,7 +24,7 @@ public function setForm(FormInterface $form) /** * @FormValidation - * + * * = is same as @ FormValidation(form="form", onFailure="createActionValidationFailed") */ public function createAction($name) diff --git a/tests/Fake/FakeControllerVndError.php b/tests/Fake/FakeControllerVndError.php index e3cf8b9..3f44ab5 100644 --- a/tests/Fake/FakeControllerVndError.php +++ b/tests/Fake/FakeControllerVndError.php @@ -4,7 +4,7 @@ use Ray\Di\Di\Inject; use Ray\Di\Di\Named; -use Ray\WebFormModule\Annotation\FormValidation; +use Ray\WebFormModule\Annotation\InputValidation; use Ray\WebFormModule\Annotation\VndError; class FakeControllerVndError @@ -24,10 +24,11 @@ public function setForm(FormInterface $form) } /** - * @FormValidation(form="form1", onFailure="badRequestAction") + * @InputValidation(form="form1") * @VndError( * message="foo validation failed", - * logref="a1000", path="/path/to/error", + * logref="a1000", + * path="/path/to/error", * href={"_self"="/path/to/error", "help"="/path/to/help"} * ) */ diff --git a/tests/Fake/FakeInputValidationController.php b/tests/Fake/FakeInputValidationController.php index 0a8cefd..9619276 100644 --- a/tests/Fake/FakeInputValidationController.php +++ b/tests/Fake/FakeInputValidationController.php @@ -11,7 +11,7 @@ class FakeInputValidationController /** * @var FormInterface */ - protected $form1; + protected $form; /** * @Inject @@ -19,11 +19,11 @@ class FakeInputValidationController */ public function setForm(FormInterface $form) { - $this->form1 = $form; + $this->form = $form; } /** - * @InputValidation(form="form1") + * @InputValidation */ public function createAction($name) { diff --git a/tests/Fake/FakeInvalidController2.php b/tests/Fake/FakeInvalidController2.php index e17fa56..9f6bb47 100644 --- a/tests/Fake/FakeInvalidController2.php +++ b/tests/Fake/FakeInvalidController2.php @@ -9,7 +9,7 @@ class FakeInvalidController2 private $form = null; /** - * @FormValidation(form="form") + * @FormValidation */ public function createAction() { diff --git a/tests/Fake/FakeInvalidInstanceController.php b/tests/Fake/FakeInvalidInstanceController.php index 76aa509..d64b9c6 100644 --- a/tests/Fake/FakeInvalidInstanceController.php +++ b/tests/Fake/FakeInvalidInstanceController.php @@ -9,7 +9,7 @@ class FakeInvalidInstanceController private $form; /** - * @FormValidation(form="form") + * @FormValidation */ public function createAction() {