Skip to content

Commit

Permalink
Test Case for Hash::maxDimensions
Browse files Browse the repository at this point in the history
Added test case for Hash::maxDimensions using the example array in pull request #7040.
  • Loading branch information
Chris Valliere authored and markstory committed Jul 21, 2015
1 parent 23b3b1a commit 7b2d7ad
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lib/Cake/Test/Case/Utility/HashTest.php
Expand Up @@ -303,6 +303,12 @@ public function testMaxDimensions() {
$data = array('1' => array('1.1' => '1.1.1'), '2', '3' => array('3.1' => array('3.1.1' => '3.1.1.1')));
$result = Hash::maxDimensions($data);
$this->assertEquals($result, 3);

$data = array('1' => array('1.1' => '1.1.1', '1.2' => array('1.2.1' => '1.2.1.1')),'2' => array(
'2.1' => '2.1.1',)
);
$result = Hash::maxDimensions($data);
$this->assertEquals($result, 3);

$data = array(
'1' => array('1.1' => '1.1.1'),
Expand Down

0 comments on commit 7b2d7ad

Please sign in to comment.