Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F6085253
AssociativeArrayTest.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
738 B
Referenced Files
None
Subscribers
None
AssociativeArrayTest.php
View Options
<?php
use
Eris\Generators
;
class
AssociativeArrayTest
extends
\PHPUnit\Framework\TestCase
{
use
Eris\TestTrait
;
public
function
testAssociativeArraysGeneratedOnStandardKeys
()
{
$this
->
forAll
(
Generators
::
associative
([
'letter'
=>
Generators
::
elements
(
"A"
,
"B"
,
"C"
),
'cipher'
=>
Generators
::
choose
(
0
,
9
),
])
)
->
then
(
function
(
$array
)
{
$this
->
assertCount
(
2
,
$array
);
$letter
=
$array
[
'letter'
];
\Eris\PHPUnitDeprecationHelper
::
assertIsString
(
$letter
);
$cipher
=
$array
[
'cipher'
];
\Eris\PHPUnitDeprecationHelper
::
assertIsInt
(
$cipher
);
});
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Oct 5 2026, 13:35 (6 w, 1 d ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
ab/7f/1b66ed7ebf0b4dda85ca7a279bc6
Default Alt Text
AssociativeArrayTest.php (738 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment