From 495c731f1b1cb15b3f8e58341e638f2f119d6de7 Mon Sep 17 00:00:00 2001 From: ADmad Date: Sat, 30 Nov 2024 13:33:56 +0530 Subject: [PATCH] Simplify HTML for help text block. Use "div" instead of "small" to avoid use of "d-block". Remove "text-muted" as "form-text" already applies the secondary color. --- src/View/Helper/FormHelper.php | 47 +++++++++---------- .../DefaultAlign/CheckboxControlTest.php | 30 ++++++------ .../DefaultAlign/ColorControlTest.php | 20 ++++---- .../DefaultAlign/DateTimeControlTest.php | 20 ++++---- .../DefaultAlign/FileControlTest.php | 20 ++++---- .../MultipleCheckboxControlTest.php | 34 +++++++------- .../DefaultAlign/RadioControlTest.php | 30 ++++++------ .../DefaultAlign/RangeControlTest.php | 20 ++++---- .../DefaultAlign/SelectControlTest.php | 20 ++++---- .../DefaultAlign/StaticControlTest.php | 20 ++++---- .../DefaultAlign/TextControlTest.php | 20 ++++---- .../HorizontalAlign/CheckboxControlTest.php | 30 ++++++------ .../HorizontalAlign/ColorControlTest.php | 20 ++++---- .../HorizontalAlign/DateTimeControlTest.php | 20 ++++---- .../HorizontalAlign/FileControlTest.php | 20 ++++---- .../MultipleCheckboxControlTest.php | 30 ++++++------ .../HorizontalAlign/RadioControlTest.php | 30 ++++++------ .../HorizontalAlign/RangeControlTest.php | 20 ++++---- .../HorizontalAlign/SelectControlTest.php | 20 ++++---- .../HorizontalAlign/StaticControlTest.php | 20 ++++---- .../HorizontalAlign/TextControlTest.php | 20 ++++---- .../InlineAlign/CheckboxControlTest.php | 30 ++++++------ .../InlineAlign/ColorControlTest.php | 20 ++++---- .../InlineAlign/DateTimeControlTest.php | 20 ++++---- .../InlineAlign/FileControlTest.php | 20 ++++---- .../MultipleCheckboxControlTest.php | 20 ++++---- .../InlineAlign/RadioControlTest.php | 20 ++++---- .../InlineAlign/RangeControlTest.php | 20 ++++---- .../InlineAlign/SelectControlTest.php | 20 ++++---- .../InlineAlign/StaticControlTest.php | 20 ++++---- .../InlineAlign/TextControlTest.php | 20 ++++---- 31 files changed, 358 insertions(+), 363 deletions(-) diff --git a/src/View/Helper/FormHelper.php b/src/View/Helper/FormHelper.php index 0df40c00..97890ef2 100644 --- a/src/View/Helper/FormHelper.php +++ b/src/View/Helper/FormHelper.php @@ -141,7 +141,7 @@ class FormHelper extends CoreFormHelper 'label' => '{{text}}{{tooltip}}', 'help' => - '{{content}}', + '{{content}}', 'tooltip' => '', 'formGroupFloatingLabel' => @@ -980,36 +980,31 @@ protected function _placeholderOptions(string $fieldName, array $options): array */ protected function _helpOptions(string $fieldName, array $options): array { - if ($options['help']) { - if (!is_array($options['help'])) { - $options['help'] = [ - 'content' => $options['help'], - ]; - } + if ($options['help'] === null) { + return $options; + } - if (!isset($options['help']['id'])) { - $options['help']['id'] = $this->_domId($fieldName . '-help'); - } + if (!is_array($options['help'])) { + $options['help'] = [ + 'content' => $options['help'], + ]; + } - $helpClasses = []; - if ($this->_align === static::ALIGN_INLINE) { - $helpClasses[] = 'visually-hidden'; - } else { - $helpClasses[] = 'd-block'; - } + if (!isset($options['help']['id'])) { + $options['help']['id'] = $this->_domId($fieldName . '-help'); + } - $helpClasses[] = 'form-text'; - if ($this->_align !== static::ALIGN_INLINE) { - $helpClasses[] = 'text-muted'; - } + $helpClasses = ['form-text']; + if ($this->_align === static::ALIGN_INLINE) { + $helpClasses[] = 'visually-hidden'; + } - $options['help'] = $this->injectClasses($helpClasses, $options['help']); + $options['help'] = $this->injectClasses($helpClasses, $options['help']); - $options['help'] = $this->templater()->format('help', [ - 'content' => $options['help']['content'], - 'attrs' => $this->templater()->formatAttributes($options['help'], ['content']), - ]); - } + $options['help'] = $this->templater()->format('help', [ + 'content' => $options['help']['content'], + 'attrs' => $this->templater()->formatAttributes($options['help'], ['content']), + ]); return $options; } diff --git a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/CheckboxControlTest.php b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/CheckboxControlTest.php index f446d0fe..aa40e364 100644 --- a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/CheckboxControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/CheckboxControlTest.php @@ -157,9 +157,9 @@ public function testDefaultAlignCheckboxControlWithHelp() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -196,13 +196,13 @@ public function testDefaultAlignCheckboxControlWithHelpOptions() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -347,9 +347,9 @@ public function testDefaultAlignCheckboxControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -394,13 +394,13 @@ public function testDefaultAlignCheckboxControlWithErrorAndHelpAndOptions() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -750,9 +750,9 @@ public function testDefaultAlignCheckboxControlInlineWithHelp() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => ['id' => 'users-help','class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help','class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -790,13 +790,13 @@ public function testDefaultAlignCheckboxControlInlineWithHelpOptions() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); diff --git a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/ColorControlTest.php b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/ColorControlTest.php index 7e9e9c5d..daeee542 100644 --- a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/ColorControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/ColorControlTest.php @@ -133,9 +133,9 @@ public function testDefaultAlignColorControlWithHelp() 'aria-describedby' => 'color-help', 'value' => '#ffffff', ], - ['small' => ['id' => 'color-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'color-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -168,13 +168,13 @@ public function testDefaultAlignColorControlWithHelpOptions() 'aria-describedby' => 'custom-help', 'value' => '#ffffff', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -300,9 +300,9 @@ public function testDefaultAlignColorControlWithErrorAndHelp() ['div' => ['id' => 'color-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'color-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'color-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -342,13 +342,13 @@ public function testDefaultAlignColorControlWithErrorAndHelpOptions() ['div' => ['id' => 'color-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); diff --git a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/DateTimeControlTest.php b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/DateTimeControlTest.php index 8800655b..a2e3d499 100644 --- a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/DateTimeControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/DateTimeControlTest.php @@ -159,9 +159,9 @@ public function testDefaultAlignDateTimeControlWithHelp() 'step' => '1', 'value' => date('H:i:s', $now), ], - ['small' => ['id' => 'created-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'created-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -197,13 +197,13 @@ public function testDefaultAlignDateTimeControlWithHelpOptions() 'step' => '1', 'value' => date('H:i:s', $now), ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -346,9 +346,9 @@ public function testDefaultAlignDateTimeControlWithErrorAndHelp() ['div' => ['id' => 'created-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'created-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'created-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -393,13 +393,13 @@ public function testDefaultAlignDateTimeControlWithErrorAndHelpOptions() ['div' => ['id' => 'created-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); diff --git a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/FileControlTest.php b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/FileControlTest.php index 599c6a6f..e03fe8e4 100644 --- a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/FileControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/FileControlTest.php @@ -127,9 +127,9 @@ public function testDefaultAlignFileControlWithHelp() 'class' => 'form-control', 'aria-describedby' => 'file-help', ]], - ['small' => ['id' => 'file-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'file-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -160,13 +160,13 @@ public function testDefaultAlignFileControlWithHelpOptions() 'class' => 'form-control', 'aria-describedby' => 'custom-help', ]], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -284,9 +284,9 @@ public function testDefaultAlignFileControlWithErrorAndHelp() ['div' => ['id' => 'file-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'file-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'file-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -324,13 +324,13 @@ public function testDefaultAlignFileControlWithErrorAndHelpOptions() ['div' => ['id' => 'file-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); diff --git a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/MultipleCheckboxControlTest.php b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/MultipleCheckboxControlTest.php index ba2cb5b6..ee2cadf2 100644 --- a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/MultipleCheckboxControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/MultipleCheckboxControlTest.php @@ -276,9 +276,9 @@ public function testDefaultAlignMultipleCheckboxControlWithHelp() 'option 2', '/label', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -338,13 +338,13 @@ public function testDefaultAlignMultipleCheckboxControlWithHelpOptions() 'option 2', '/label', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -538,9 +538,9 @@ public function testDefaultAlignMultipleCheckboxControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -613,13 +613,13 @@ public function testDefaultAlignMultipleCheckboxControlWithErrorAndHelpOptions() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -688,9 +688,9 @@ public function testDefaultAlignMultipleCheckboxControlCustomAriaDescribedByWith ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -1212,9 +1212,9 @@ public function testDefaultAlignMultipleCheckboxControlInlineWithHelp() 'option 2', '/label', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -1279,13 +1279,13 @@ public function testDefaultAlignMultipleCheckboxControlInlineWithHelpOptions() 'option 2', '/label', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); diff --git a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/RadioControlTest.php b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/RadioControlTest.php index 10ec5a83..9815ebb4 100644 --- a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/RadioControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/RadioControlTest.php @@ -264,9 +264,9 @@ public function testDefaultAlignRadioControlWithHelp() 'option 2', '/label', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -326,13 +326,13 @@ public function testDefaultAlignRadioControlWithHelpOptions() 'option 2', '/label', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -527,9 +527,9 @@ public function testDefaultAlignRadioControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -602,13 +602,13 @@ public function testDefaultAlignRadioControlWithErrorAndHelpOptions() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -1065,9 +1065,9 @@ public function testDefaultAlignRadioControlInlineWithHelp() 'option 2', '/label', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -1128,13 +1128,13 @@ public function testDefaultAlignRadioControlInlineWithHelpOptions() 'option 2', '/label', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); diff --git a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/RangeControlTest.php b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/RangeControlTest.php index 61b3e62f..f0c2f50e 100644 --- a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/RangeControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/RangeControlTest.php @@ -153,9 +153,9 @@ public function testDefaultAlignRangeControlWithHelp() 'class' => 'form-range', 'aria-describedby' => 'height-help', ], - ['small' => ['id' => 'height-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'height-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -192,13 +192,13 @@ public function testDefaultAlignRangeControlWithHelpOptions() 'class' => 'form-range', 'aria-describedby' => 'custom-help', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -340,9 +340,9 @@ public function testDefaultAlignRangeControlWithErrorAndHelp() ['div' => ['id' => 'height-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'height-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'height-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -386,13 +386,13 @@ public function testDefaultAlignRangeControlWithErrorAndHelpOptions() ['div' => ['id' => 'height-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); diff --git a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/SelectControlTest.php b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/SelectControlTest.php index b76ba9a3..6cdcf4ad 100644 --- a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/SelectControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/SelectControlTest.php @@ -189,9 +189,9 @@ public function testDefaultAlignSelectControlWithHelp() 'option 2', '/option', '/select', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -232,13 +232,13 @@ public function testDefaultAlignSelectControlWithHelpOptions() 'option 2', '/option', '/select', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -388,9 +388,9 @@ public function testDefaultAlignSelectControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -438,13 +438,13 @@ public function testDefaultAlignSelectControlWithErrorAndHelpOptions() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); diff --git a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/StaticControlTest.php b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/StaticControlTest.php index cbd07f1f..6f868996 100644 --- a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/StaticControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/StaticControlTest.php @@ -179,9 +179,9 @@ public function testDefaultAlignStaticControlWithHelp() 'aria-describedby' => 'title-help', 'value' => 'title', ], - ['small' => ['id' => 'title-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'title-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -217,13 +217,13 @@ public function testDefaultAlignStaticControlWithHelpOptions() 'aria-describedby' => 'custom-help', 'value' => 'title', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -364,9 +364,9 @@ public function testDefaultAlignStaticControlWithErrorAndHelp() ['div' => ['id' => 'title-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'title-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'title-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -410,13 +410,13 @@ public function testDefaultAlignStaticControlWithErrorAndHelpOptions() ['div' => ['id' => 'title-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); diff --git a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/TextControlTest.php b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/TextControlTest.php index 85db4ff5..2bbd0c28 100644 --- a/tests/TestCase/View/Helper/FormHelper/DefaultAlign/TextControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/DefaultAlign/TextControlTest.php @@ -228,9 +228,9 @@ public function testDefaultAlignTextControlWithHelp() 'class' => 'form-control', 'aria-describedby' => 'title-help', ], - ['small' => ['id' => 'title-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'title-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -261,13 +261,13 @@ public function testDefaultAlignTextControlWithHelpOptions() 'class' => 'form-control', 'aria-describedby' => 'custom-help', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -361,9 +361,9 @@ public function testDefaultAlignTextControlWithErrorAndHelp() ['div' => ['id' => 'title-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'title-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'title-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); @@ -401,13 +401,13 @@ public function testDefaultAlignTextControlWithErrorAndHelpOptions() ['div' => ['id' => 'title-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', ]; $this->assertHtml($expected, $result); diff --git a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/CheckboxControlTest.php b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/CheckboxControlTest.php index 8e5f09fc..b196722f 100644 --- a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/CheckboxControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/CheckboxControlTest.php @@ -207,9 +207,9 @@ public function testHorizontalAlignCheckboxControlWithHelp() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', '/div', @@ -257,13 +257,13 @@ public function testHorizontalAlignCheckboxControlWithHelpOptions() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', '/div', @@ -452,9 +452,9 @@ public function testHorizontalAlignCheckboxControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', '/div', @@ -510,13 +510,13 @@ public function testHorizontalAlignCheckboxControlWithErrorAndHelpOptions() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', '/div', @@ -972,9 +972,9 @@ public function testHorizontalAlignCheckboxControlInlineWithHelp() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', '/div', @@ -1023,13 +1023,13 @@ public function testHorizontalAlignCheckboxControlInlineWithHelpOptions() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', '/div', diff --git a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/ColorControlTest.php b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/ColorControlTest.php index 7870895a..6cb7d29b 100644 --- a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/ColorControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/ColorControlTest.php @@ -185,9 +185,9 @@ public function testHorizontalAlignColorControlWithHelp() 'aria-describedby' => 'color-help', 'value' => '#ffffff', ], - ['small' => ['id' => 'color-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'color-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -230,13 +230,13 @@ public function testHorizontalAlignColorControlWithHelpOptions() 'aria-describedby' => 'custom-help', 'value' => '#ffffff', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -401,9 +401,9 @@ public function testHorizontalAlignColorControlWithErrorAndHelp() ['div' => ['id' => 'color-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'color-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'color-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -453,13 +453,13 @@ public function testHorizontalAlignColorControlWithErrorAndHelpOptions() ['div' => ['id' => 'color-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/DateTimeControlTest.php b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/DateTimeControlTest.php index a95e19d8..a0096d8b 100644 --- a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/DateTimeControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/DateTimeControlTest.php @@ -190,9 +190,9 @@ public function testHorizontalAlignDateTimeControlWithHelp() 'step' => '1', 'value' => date('H:i:s', $now), ], - ['small' => ['id' => 'created-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'created-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -237,13 +237,13 @@ public function testHorizontalAlignDateTimeControlWithHelpOptions() 'step' => '1', 'value' => date('H:i:s', $now), ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -419,9 +419,9 @@ public function testHorizontalAlignDateTimeControlWithErrorAndHelp() ['div' => ['id' => 'created-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'created-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'created-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -474,13 +474,13 @@ public function testHorizontalAlignDateTimeControlWithErrorAndHelpOptions() ['div' => ['id' => 'created-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/FileControlTest.php b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/FileControlTest.php index 3d77a77d..49a2867f 100644 --- a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/FileControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/FileControlTest.php @@ -172,9 +172,9 @@ public function testHorizontalAlignFileControlWithHelp() 'class' => 'form-control', 'aria-describedby' => 'file-help', ]], - ['small' => ['id' => 'file-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'file-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -214,13 +214,13 @@ public function testHorizontalAlignFileControlWithHelpOptions() 'class' => 'form-control', 'aria-describedby' => 'custom-help', ]], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -374,9 +374,9 @@ public function testHorizontalAlignFileControlWithErrorAndHelp() ['div' => ['id' => 'file-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'file-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'file-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -423,13 +423,13 @@ public function testHorizontalAlignFileControlWithErrorAndHelpOptions() ['div' => ['id' => 'file-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/MultipleCheckboxControlTest.php b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/MultipleCheckboxControlTest.php index c4fb137e..7c32cb80 100644 --- a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/MultipleCheckboxControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/MultipleCheckboxControlTest.php @@ -329,9 +329,9 @@ public function testHorizontalAlignMultipleCheckboxControlWithHelp() 'option 2', '/label', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -404,13 +404,13 @@ public function testHorizontalAlignMultipleCheckboxControlWithHelpOptions() 'option 2', '/label', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -640,9 +640,9 @@ public function testHorizontalAlignMultipleCheckboxControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -724,13 +724,13 @@ public function testHorizontalAlignMultipleCheckboxControlWithErrorAndHelpOption ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -1345,9 +1345,9 @@ public function testHorizontalAlignMultipleCheckboxControlInlineWithHelp() 'option 2', '/label', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -1421,13 +1421,13 @@ public function testHorizontalAlignMultipleCheckboxControlInlineWithHelpOptions( 'option 2', '/label', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/RadioControlTest.php b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/RadioControlTest.php index 595b70fa..41c4b0f4 100644 --- a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/RadioControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/RadioControlTest.php @@ -309,9 +309,9 @@ public function testHorizontalAlignRadioControlWithHelp() 'option 2', '/label', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -380,13 +380,13 @@ public function testHorizontalAlignRadioControlWithHelpOptions() 'option 2', '/label', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -617,9 +617,9 @@ public function testHorizontalAlignRadioControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -701,13 +701,13 @@ public function testHorizontalAlignRadioControlWithErrorAndHelpOptions() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -1310,9 +1310,9 @@ public function testHorizontalAlignRadioControlInlineWithHelp() 'option 2', '/label', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -1382,13 +1382,13 @@ public function testHorizontalAlignRadioControlInlineWithHelpOptions() 'option 2', '/label', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/RangeControlTest.php b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/RangeControlTest.php index 430c4797..31f96fd5 100644 --- a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/RangeControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/RangeControlTest.php @@ -202,9 +202,9 @@ public function testHorizontalAlignRangeControlWithHelp() 'class' => 'form-range', 'aria-describedby' => 'height-help', ], - ['small' => ['id' => 'height-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'height-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -250,13 +250,13 @@ public function testHorizontalAlignRangeControlWithHelpOptions() 'class' => 'form-range', 'aria-describedby' => 'custom-help', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -434,9 +434,9 @@ public function testHorizontalAlignRangeControlWithErrorAndHelp() ['div' => ['id' => 'height-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'height-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'height-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -489,13 +489,13 @@ public function testHorizontalAlignRangeControlWithErrorAndHelpOptions() ['div' => ['id' => 'height-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/SelectControlTest.php b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/SelectControlTest.php index acecefe1..741a946b 100644 --- a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/SelectControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/SelectControlTest.php @@ -247,9 +247,9 @@ public function testHorizontalAlignSelectControlWithHelp() 'option 2', '/option', '/select', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -299,13 +299,13 @@ public function testHorizontalAlignSelectControlWithHelpOptions() 'option 2', '/option', '/select', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -491,9 +491,9 @@ public function testHorizontalAlignSelectControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'users-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -550,13 +550,13 @@ public function testHorizontalAlignSelectControlWithErrorAndHelpOptions() ['div' => ['id' => 'users-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/StaticControlTest.php b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/StaticControlTest.php index 4ed3bfe0..b52395dc 100644 --- a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/StaticControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/StaticControlTest.php @@ -233,9 +233,9 @@ public function testHorizontalAlignStaticControlWithHelp() 'aria-describedby' => 'title-help', 'value' => 'title', ], - ['small' => ['id' => 'title-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'title-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -280,13 +280,13 @@ public function testHorizontalAlignStaticControlWithHelpOptions() 'aria-describedby' => 'custom-help', 'value' => 'title', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -463,9 +463,9 @@ public function testHorizontalAlignStaticControlWithErrorAndHelp() ['div' => ['id' => 'title-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'title-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'title-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -518,13 +518,13 @@ public function testHorizontalAlignStaticControlWithErrorAndHelpOptions() ['div' => ['id' => 'title-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/TextControlTest.php b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/TextControlTest.php index f630985a..c705441d 100644 --- a/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/TextControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/HorizontalAlign/TextControlTest.php @@ -313,9 +313,9 @@ public function testHorizontalAlignTextControlWithHelp() 'class' => 'form-control', 'aria-describedby' => 'title-help', ], - ['small' => ['id' => 'title-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'title-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -355,13 +355,13 @@ public function testHorizontalAlignTextControlWithHelpOptions() 'class' => 'form-control', 'aria-describedby' => 'custom-help', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -482,9 +482,9 @@ public function testHorizontalAlignTextControlWithErrorAndHelp() ['div' => ['id' => 'title-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => ['id' => 'title-help', 'class' => 'd-block form-text text-muted']], + ['div' => ['id' => 'title-help', 'class' => 'form-text']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -531,13 +531,13 @@ public function testHorizontalAlignTextControlWithErrorAndHelpOptions() ['div' => ['id' => 'title-error', 'class' => 'ms-0 invalid-feedback']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class d-block form-text text-muted', + 'class' => 'help-class form-text', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/InlineAlign/CheckboxControlTest.php b/tests/TestCase/View/Helper/FormHelper/InlineAlign/CheckboxControlTest.php index 6034dddd..0e3983bb 100644 --- a/tests/TestCase/View/Helper/FormHelper/InlineAlign/CheckboxControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/InlineAlign/CheckboxControlTest.php @@ -182,9 +182,9 @@ public function testInlineAlignCheckboxControlWithHelp() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => ['id' => 'users-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'users-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -227,13 +227,13 @@ public function testInlineAlignCheckboxControlWithHelpOptions() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -365,9 +365,9 @@ public function testInlineAlignCheckboxControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'users-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -418,13 +418,13 @@ public function testInlineAlignCheckboxControlWithErrorAndHelpOptions() ['div' => ['id' => 'users-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -671,9 +671,9 @@ public function testInlineAlignCheckboxControlInlineWithHelp() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => ['id' => 'users-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'users-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -717,13 +717,13 @@ public function testInlineAlignCheckboxControlInlineWithHelpOptions() ['label' => ['class' => 'form-check-label', 'for' => 'users']], 'Users', '/label', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/InlineAlign/ColorControlTest.php b/tests/TestCase/View/Helper/FormHelper/InlineAlign/ColorControlTest.php index f7579cef..14862491 100644 --- a/tests/TestCase/View/Helper/FormHelper/InlineAlign/ColorControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/InlineAlign/ColorControlTest.php @@ -156,9 +156,9 @@ public function testInlineAlignColorControlWithHelp() 'aria-describedby' => 'color-help', 'value' => '#ffffff', ], - ['small' => ['id' => 'color-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'color-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -195,13 +195,13 @@ public function testInlineAlignColorControlWithHelpOptions() 'aria-describedby' => 'custom-help', 'value' => '#ffffff', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -313,9 +313,9 @@ public function testInlineAlignColorControlWithErrorAndHelp() ['div' => ['id' => 'color-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => ['id' => 'color-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'color-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -359,13 +359,13 @@ public function testInlineAlignColorControlWithErrorAndHelpOptions() ['div' => ['id' => 'color-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/InlineAlign/DateTimeControlTest.php b/tests/TestCase/View/Helper/FormHelper/InlineAlign/DateTimeControlTest.php index 85569029..8160b269 100644 --- a/tests/TestCase/View/Helper/FormHelper/InlineAlign/DateTimeControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/InlineAlign/DateTimeControlTest.php @@ -177,9 +177,9 @@ public function testInlineAlignDateTimeControlWithHelp() 'aria-describedby' => 'created-help', 'value' => $now->format('Y-m-d H:i:s'), ], - ['small' => ['id' => 'created-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'created-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -220,13 +220,13 @@ public function testInlineAlignDateTimeControlWithHelpOptions() 'aria-describedby' => 'custom-help', 'value' => $now->format('Y-m-d H:i:s'), ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -394,9 +394,9 @@ public function testInlineAlignDateTimeControlWithErrorAndHelp() ['div' => ['id' => 'created-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => ['id' => 'created-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'created-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -446,13 +446,13 @@ public function testInlineAlignDateTimeControlWithErrorAndHelpOptions() ['div' => ['id' => 'created-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/InlineAlign/FileControlTest.php b/tests/TestCase/View/Helper/FormHelper/InlineAlign/FileControlTest.php index 29e97ee9..3f5f51a2 100644 --- a/tests/TestCase/View/Helper/FormHelper/InlineAlign/FileControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/InlineAlign/FileControlTest.php @@ -156,9 +156,9 @@ public function testInlineAlignFileControlWithHelp() 'class' => 'form-control', 'aria-describedby' => 'file-help', ]], - ['small' => ['id' => 'file-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'file-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -195,13 +195,13 @@ public function testInlineAlignFileControlWithHelpOptions() 'class' => 'form-control', 'aria-describedby' => 'custom-help', ]], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -313,9 +313,9 @@ public function testInlineAlignFileControlWithErrorAndHelp() ['div' => ['id' => 'file-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => ['id' => 'file-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'file-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -359,13 +359,13 @@ public function testInlineAlignFileControlWithErrorAndHelpOptions() ['div' => ['id' => 'file-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/InlineAlign/MultipleCheckboxControlTest.php b/tests/TestCase/View/Helper/FormHelper/InlineAlign/MultipleCheckboxControlTest.php index 29776ae5..1fed1aae 100644 --- a/tests/TestCase/View/Helper/FormHelper/InlineAlign/MultipleCheckboxControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/InlineAlign/MultipleCheckboxControlTest.php @@ -317,9 +317,9 @@ public function testInlineAlignMultipleCheckboxControlWithHelp() 'option 2', '/label', '/div', - ['small' => ['id' => 'users-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'users-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -389,13 +389,13 @@ public function testInlineAlignMultipleCheckboxControlWithHelpOptions() 'option 2', '/label', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -582,9 +582,9 @@ public function testInlineAlignMultipleCheckboxControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'users-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -663,13 +663,13 @@ public function testInlineAlignMultipleCheckboxControlWithErrorAndHelpOptions() ['div' => ['id' => 'users-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/InlineAlign/RadioControlTest.php b/tests/TestCase/View/Helper/FormHelper/InlineAlign/RadioControlTest.php index 61cffe63..c9e26094 100644 --- a/tests/TestCase/View/Helper/FormHelper/InlineAlign/RadioControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/InlineAlign/RadioControlTest.php @@ -318,9 +318,9 @@ public function testInlineAlignRadioControlWithHelp() 'option 2', '/label', '/div', - ['small' => ['id' => 'users-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'users-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -390,13 +390,13 @@ public function testInlineAlignRadioControlWithHelpOptions() 'option 2', '/label', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -582,9 +582,9 @@ public function testInlineAlignRadioControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'users-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -663,13 +663,13 @@ public function testInlineAlignRadioControlWithErrorAndHelpOptions() ['div' => ['id' => 'users-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/InlineAlign/RangeControlTest.php b/tests/TestCase/View/Helper/FormHelper/InlineAlign/RangeControlTest.php index e0229cba..4e80be29 100644 --- a/tests/TestCase/View/Helper/FormHelper/InlineAlign/RangeControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/InlineAlign/RangeControlTest.php @@ -176,9 +176,9 @@ public function testInlineAlignRangeControlWithHelp() 'class' => 'form-range', 'aria-describedby' => 'height-help', ], - ['small' => ['id' => 'height-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'height-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -219,13 +219,13 @@ public function testInlineAlignRangeControlWithHelpOptions() 'class' => 'form-range', 'aria-describedby' => 'custom-help', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -349,9 +349,9 @@ public function testInlineAlignRangeControlWithErrorAndHelp() ['div' => ['id' => 'height-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => ['id' => 'height-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'height-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -399,13 +399,13 @@ public function testInlineAlignRangeControlWithErrorAndHelpOptions() ['div' => ['id' => 'height-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/InlineAlign/SelectControlTest.php b/tests/TestCase/View/Helper/FormHelper/InlineAlign/SelectControlTest.php index 44ae87c4..1c17b4ed 100644 --- a/tests/TestCase/View/Helper/FormHelper/InlineAlign/SelectControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/InlineAlign/SelectControlTest.php @@ -216,9 +216,9 @@ public function testInlineAlignSelectControlWithHelp() 'option 2', '/option', '/select', - ['small' => ['id' => 'users-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'users-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -263,13 +263,13 @@ public function testInlineAlignSelectControlWithHelpOptions() 'option 2', '/option', '/select', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -401,9 +401,9 @@ public function testInlineAlignSelectControlWithErrorAndHelp() ['div' => ['id' => 'users-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => ['id' => 'users-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'users-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -455,13 +455,13 @@ public function testInlineAlignSelectControlWithErrorAndHelpOptions() ['div' => ['id' => 'users-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/InlineAlign/StaticControlTest.php b/tests/TestCase/View/Helper/FormHelper/InlineAlign/StaticControlTest.php index d1730a3b..cdd58cdd 100644 --- a/tests/TestCase/View/Helper/FormHelper/InlineAlign/StaticControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/InlineAlign/StaticControlTest.php @@ -206,9 +206,9 @@ public function testInlineAlignStaticControlWithHelp() 'aria-describedby' => 'title-help', 'value' => 'title', ], - ['small' => ['id' => 'title-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'title-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -248,13 +248,13 @@ public function testInlineAlignStaticControlWithHelpOptions() 'aria-describedby' => 'custom-help', 'value' => 'title', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -377,9 +377,9 @@ public function testInlineAlignStaticControlWithErrorAndHelp() ['div' => ['id' => 'title-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => ['id' => 'title-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'title-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -427,13 +427,13 @@ public function testInlineAlignStaticControlWithErrorAndHelpOptions() ['div' => ['id' => 'title-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; diff --git a/tests/TestCase/View/Helper/FormHelper/InlineAlign/TextControlTest.php b/tests/TestCase/View/Helper/FormHelper/InlineAlign/TextControlTest.php index a5dd73b7..95866bff 100644 --- a/tests/TestCase/View/Helper/FormHelper/InlineAlign/TextControlTest.php +++ b/tests/TestCase/View/Helper/FormHelper/InlineAlign/TextControlTest.php @@ -267,9 +267,9 @@ public function testInlineAlignTextControlWithHelp() 'class' => 'form-control', 'aria-describedby' => 'title-help', ], - ['small' => ['id' => 'title-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'title-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -304,13 +304,13 @@ public function testInlineAlignTextControlWithHelpOptions() 'class' => 'form-control', 'aria-describedby' => 'custom-help', ], - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -415,9 +415,9 @@ public function testInlineAlignTextControlWithErrorAndHelp() ['div' => ['id' => 'title-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => ['id' => 'title-help', 'class' => 'visually-hidden form-text']], + ['div' => ['id' => 'title-help', 'class' => 'form-text visually-hidden']], 'Help text', - '/small', + '/div', '/div', '/div', ]; @@ -459,13 +459,13 @@ public function testInlineAlignTextControlWithErrorAndHelpOptions() ['div' => ['id' => 'title-error', 'class' => 'invalid-tooltip']], 'error message', '/div', - ['small' => [ + ['div' => [ 'id' => 'custom-help', 'foo' => 'bar', - 'class' => 'help-class visually-hidden form-text', + 'class' => 'help-class form-text visually-hidden', ]], 'Help text', - '/small', + '/div', '/div', '/div', ];