Airship\UnitTests\AirshipTest::testSecureShuffle PHP Method

testSecureShuffle() public method

public testSecureShuffle ( )
    public function testSecureShuffle()
    {
        $array = [];
        for ($i = 0; $i < 512; ++$i) {
            $array[] = random_int(PHP_INT_MIN, PHP_INT_MAX);
        }
        $copy = \array_values($array);
        \Airship\secure_shuffle($copy);
        $this->assertNotSame($copy, $array, 'Shuffled array should not be identical to original.');
        $this->assertCount(512, $copy, 'Shuffled array is not the correct size.');
    }