mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-18 18:46:17 +00:00
Adding test for #2488
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@4897 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
dbf0181e26
commit
0bd1a41329
1 changed files with 15 additions and 0 deletions
|
@ -161,6 +161,21 @@ class SetTest extends UnitTestCase {
|
|||
// And also updates it's own value property
|
||||
$this->assertIdentical($Set->value, $expected);
|
||||
}
|
||||
|
||||
function testExtract() {
|
||||
$a = array(
|
||||
array( 'lday' => '20 sales' ),
|
||||
array( 'lday' => '2 sales' )
|
||||
);
|
||||
$result = Set::extract($a, '{n}.lday');
|
||||
|
||||
$expected = array(
|
||||
0 => '20 sales',
|
||||
1 => '2 sales'
|
||||
);
|
||||
|
||||
$this->assertIdentical($result, $expected);
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
Loading…
Add table
Reference in a new issue