Skip to content
This repository
Browse code

MINOR Fixing E_STRICT compliance in simpletest

  • Loading branch information...
commit 972dfee5c32655934a9c99336872dea4d0fa9aa9 1 parent 41433f1
Sean Harvey authored April 12, 2012
4  thirdparty/simpletest/compatibility.php
@@ -19,7 +19,7 @@ class SimpleTestCompatibility {
19 19
      *    @access public
20 20
      *    @static
21 21
      */
22  
-    function copy($object) {
  22
+    static function copy($object) {
23 23
         if (version_compare(phpversion(), '5') >= 0) {
24 24
             eval('$copy = clone $object;');
25 25
             return $copy;
@@ -170,4 +170,4 @@ function setTimeout($handle, $timeout) {
170 170
         }
171 171
     }
172 172
 }
173  
-?>
  173
+?>
4  thirdparty/simpletest/form.php
@@ -120,7 +120,7 @@ function _encode() {
120 120
         $class = $this->_encoding;
121 121
         $encoding = new $class();
122 122
         for ($i = 0, $count = count($this->_widgets); $i < $count; $i++) {
123  
-            $this->_widgets[$i]->write($encoding);
  123
+            $this->_widgets[$i]->write($encoding, 0, 0);
124 124
         }
125 125
         return $encoding;
126 126
     }
@@ -305,7 +305,7 @@ function submitButton($selector, $additional = false) {
305 305
         foreach ($this->_buttons as $button) {
306 306
             if ($selector->isMatch($button)) {
307 307
                 $encoding = $this->_encode();
308  
-                $button->write($encoding);
  308
+                $button->write($encoding, 0, 0);
309 309
                 if ($additional) {
310 310
                     $encoding->merge($additional);
311 311
                 }
2  thirdparty/simpletest/page.php
@@ -980,4 +980,4 @@ function getField($selector) {
980 980
         return null;
981 981
     }
982 982
 }
983  
-?>
  983
+
6  thirdparty/simpletest/parser.php
@@ -690,7 +690,7 @@ function ignore($token, $event) {
690 690
      *    @access public
691 691
      *    @static
692 692
      */
693  
-    function decodeHtml($html) {
  693
+    static function decodeHtml($html) {
694 694
         return html_entity_decode($html, ENT_QUOTES);
695 695
     }
696 696
     
@@ -703,7 +703,7 @@ function decodeHtml($html) {
703 703
      *    @access public
704 704
      *    @static
705 705
      */
706  
-    function normalise($html) {
  706
+    static function normalise($html) {
707 707
         $text = preg_replace('|<!--.*?-->|', '', $html);
708 708
         $text = preg_replace('|<script[^>]*>.*?</script>|', '', $text);
709 709
         $text = preg_replace('|<img[^>]*alt\s*=\s*"([^"]*)"[^>]*>|', ' \1 ', $text);
@@ -761,4 +761,4 @@ function endElement($name) {
761 761
     function addContent($text) {
762 762
     }
763 763
 }
764  
-?>
  764
+
6  thirdparty/simpletest/tag.php
@@ -325,7 +325,7 @@ function isLabel($label) {
325 325
      *    @param SimpleEncoding $encoding    Form packet.
326 326
      *    @access public
327 327
      */
328  
-    function write(&$encoding) {
  328
+    function write(&$encoding, $x, $y) {
329 329
         if ($this->getName()) {
330 330
             $encoding->add($this->getName(), $this->getValue());
331 331
         }
@@ -680,7 +680,7 @@ function expectEndTag() {
680 680
      *    @param SimpleEncoding $encoding    Form packet.
681 681
      *    @access public
682 682
      */
683  
-    function write(&$encoding) {
  683
+    function write(&$encoding, $x, $y) {
684 684
         if (! file_exists($this->getValue())) {
685 685
             return;
686 686
         }
@@ -1415,4 +1415,4 @@ function expectEndTag() {
1415 1415
         return false;
1416 1416
     }
1417 1417
 }
1418  
-?>
  1418
+

0 notes on commit 972dfee

Please sign in to comment.
Something went wrong with that request. Please try again.