@@ -20,10 +20,10 @@ public function testBuildCommand()
2020 {
2121 $ expected = 'growlnotify -t \'Hello \' -m World ' ;
2222 $ result = $ this ->Growl
23- ->setOptions (array (
23+ ->setOptions ([
2424 'title ' => 'Hello ' ,
2525 'message ' => 'World '
26- ) )
26+ ] )
2727 ->setSafe ('message ' )
2828 ->buildCommand ();
2929
@@ -32,50 +32,50 @@ public function testBuildCommand()
3232
3333 public function testSet ()
3434 {
35- $ expected = array (
35+ $ expected = [
3636 'hello ' => 'world ' ,
3737 'title ' => 'Hey ' ,
3838 'message ' => 'Whatsup? '
39- ) ;
39+ ] ;
4040
4141 $ result = $ this ->Growl ->setOption ('hello ' , 'world ' )
4242 ->setOption ('title ' , 'Hey ' )
4343 ->setOption ('message ' , 'Whatsup? ' );
4444 $ this ->assertEquals ($ expected , PHPUnit_Framework_Assert::readAttribute ($ result , 'options ' ));
4545
46- $ result = $ this ->Growl ->setOptions (array (
46+ $ result = $ this ->Growl ->setOptions ([
4747 'hello ' => 'world ' ,
4848 'title ' => 'Hey ' ,
4949 'message ' => 'Whatsup? '
50- ) );
50+ ] );
5151 $ this ->assertEquals ($ expected , PHPUnit_Framework_Assert::readAttribute ($ result , 'options ' ));
5252 }
5353
5454 public function testEscape ()
5555 {
56- $ expected = array (
56+ $ expected = [
5757 'hello ' => '\'world \''
58- ) ;
58+ ] ;
5959
6060 $ growl = new Growl (new GrowlNotifyBuilder ());
6161 $ growlReflection = new ReflectionClass ($ growl );
6262 $ method = $ growlReflection ->getMethod ('escape ' );
6363 $ method ->setAccessible (true );
6464
65- $ this ->assertEquals ($ expected , $ method ->invokeArgs ($ growl , array ( array ( 'hello ' => 'world ' )) ));
65+ $ this ->assertEquals ($ expected , $ method ->invokeArgs ($ growl , [[ 'hello ' => 'world ' ]] ));
6666
67- $ expected = array (
67+ $ expected = [
6868 'hello ' => '\'world \'' ,
6969 'something ' => 'else '
70- ) ;
70+ ] ;
7171
7272 $ growl = new Growl (new GrowlNotifyBuilder ());
7373 $ growl ->setSafe ('something ' );
7474 $ growlReflection = new ReflectionClass ($ growl );
7575 $ method = $ growlReflection ->getMethod ('escape ' );
7676 $ method ->setAccessible (true );
7777
78- $ this ->assertEquals ($ expected , $ method ->invokeArgs ($ growl , array ( array ( 'hello ' => 'world ' , 'something ' => 'else ' )) ));
78+ $ this ->assertEquals ($ expected , $ method ->invokeArgs ($ growl , [[ 'hello ' => 'world ' , 'something ' => 'else ' ]] ));
7979 }
8080
8181 public function testSetEscape ()
@@ -86,12 +86,12 @@ public function testSetEscape()
8686
8787 public function testSetSafe ()
8888 {
89- $ expected = array ( 'hello ' ) ;
89+ $ expected = [ 'hello ' ] ;
9090 $ growl = $ this ->Growl ->setSafe ('hello ' );
9191 $ this ->assertEquals ($ expected , PHPUnit_Framework_Assert::readAttribute ($ growl , 'safe ' ));
9292
93- $ expected = array ( 'hello ' , 'world ' , 'again ' ) ;
94- $ growl ->setSafe (array ( 'world ' , 'again ' ) );
93+ $ expected = [ 'hello ' , 'world ' , 'again ' ] ;
94+ $ growl ->setSafe ([ 'world ' , 'again ' ] );
9595 $ this ->assertEquals ($ expected , PHPUnit_Framework_Assert::readAttribute ($ growl , 'safe ' ));
9696 }
9797
0 commit comments