| 1 | <?php |
||
| 9 | class TestController extends Controller |
||
| 10 | { |
||
| 11 | public function foo() |
||
| 12 | { |
||
| 13 | $foo = [ |
||
| 14 | ['label' => $this->get('translator')->trans('this.should.be.translated.without.errors')], //ERROR: Form label is not a scalar string |
||
| 15 | [/** @Ignore */'label' => $this->get('translator')->trans('this.should.be.translated.without.errors.and.now.it.works')], |
||
| 16 | ['label_' => $this->get('translator')->trans('this.works.correctly')], |
||
| 17 | ['label' => $this->shouldBeIgnored()], //ERROR: Form label is not a scalar string |
||
| 18 | [/** @Ignore */'label' => $this->shouldBeIgnoredAndGoesWithoutError()], |
||
| 19 | ]; |
||
| 20 | } |
||
| 21 | |||
| 22 | private function shouldBeIgnored() |
||
| 23 | { |
||
| 24 | } |
||
| 25 | |||
| 26 | private function shouldBeIgnoredAndGoesWithoutError() |
||
| 27 | { |
||
| 28 | } |
||
| 29 | } |
||
| 30 |