Mark Scherer 10 years ago
parent
commit
4c8fbf92c6
1 changed files with 3 additions and 0 deletions
  1. 3 0
      tests/TestCase/Model/Behavior/JsonableBehaviorTest.php

+ 3 - 0
tests/TestCase/Model/Behavior/JsonableBehaviorTest.php

@@ -228,6 +228,9 @@ class JsonableBehaviorTest extends TestCase {
 	}
 	}
 
 
 	public function testEncodeParamsAssocFalse() {
 	public function testEncodeParamsAssocFalse() {
+		// $depth param added in 5.5.0
+		$this->skipIf(!version_compare(PHP_VERSION, '5.5.0', '>='));
+		
 		// Test encode depth = 1
 		// Test encode depth = 1
 		$this->Comments->removeBehavior('Jsonable');
 		$this->Comments->removeBehavior('Jsonable');
 		$this->Comments->addBehavior('Tools.Jsonable', ['fields' => ['details'], 'encodeParams' => ['depth' => 1], 'decodeParams' => ['assoc' => false]]);
 		$this->Comments->addBehavior('Tools.Jsonable', ['fields' => ['details'], 'encodeParams' => ['depth' => 1], 'decodeParams' => ['assoc' => false]]);