1010use Cake \View \View ;
1111
1212class PublicBootstrapTrait {
13-
13+
1414 use BootstrapTrait ;
15-
15+
1616 public function __construct ($ View ) {
1717 $ this ->_View = $ View ;
1818 }
19-
19+
2020 public function publicEasyIcon ($ callback , $ title , $ options ) {
2121 return $ this ->_easyIcon ($ callback , $ title , $ options );
2222 }
23-
23+
2424};
2525
2626class BootstrapTraitTemplateTest extends TestCase {
27-
27+
2828 /**
2929 * Setup
3030 *
@@ -54,13 +54,14 @@ public function tearDown() {
5454 }
5555
5656 public function testEasyIcon () {
57-
57+
5858 $ that = $ this ;
5959 $ callback = function ($ text , $ options ) use ($ that ) {
60- $ that ->assertEquals (isset ($ options ['escape ' ]) ? $ options ['escape ' ] : true , $ options ['expected ' ]['escape ' ]);
60+ $ that ->assertEquals (isset ($ options ['escape ' ]) ? $ options ['escape ' ] : true ,
61+ $ options ['expected ' ]['escape ' ]);
6162 $ that ->assertHtml ($ options ['expected ' ]['result ' ], $ text );
6263 };
63-
64+
6465 $ this ->_Trait ->publicEasyIcon ($ callback , 'i:plus ' , [
6566 'expected ' => [
6667 'escape ' => false ,
@@ -69,14 +70,14 @@ public function testEasyIcon() {
6970 ]], '/i ' ]
7071 ]
7172 ]);
72-
73+
7374 $ this ->_Trait ->publicEasyIcon ($ callback , 'Click Me! ' , [
7475 'expected ' => [
7576 'escape ' => true ,
7677 'result ' => 'Click Me! '
7778 ]
7879 ]);
79-
80+
8081 $ this ->_Trait ->publicEasyIcon ($ callback , 'i:plus Add ' , [
8182 'expected ' => [
8283 'escape ' => false ,
@@ -85,7 +86,7 @@ public function testEasyIcon() {
8586 ]], '/i ' , ' Add ' ]
8687 ]
8788 ]);
88-
89+
8990 $ this ->_Trait ->publicEasyIcon ($ callback , 'Add i:plus ' , [
9091 'expected ' => [
9192 'escape ' => false ,
@@ -94,19 +95,19 @@ public function testEasyIcon() {
9495 ]], '/i ' ]
9596 ]
9697 ]);
97-
98+
9899 $ this ->_Trait ->easyIcon = false ;
99100 $ this ->_Trait ->publicEasyIcon ($ callback , 'i:plus ' , [
100101 'expected ' => [
101102 'escape ' => true ,
102103 'result ' => 'i:plus '
103104 ]
104105 ]);
105-
106+
106107 }
107-
108+
108109 public function testHelperMethods () {
109-
110+
110111 // BootstrapPaginatorHelper - TODO
111112 // BootstrapPaginatorHelper::prev($title, array $options = []);
112113 // BootstrapPaginatorHelper::next($title, array $options = []);
0 commit comments