mirror of
https://github.com/danog/endtoend-test-psl.git
synced 2024-12-02 17:56:09 +01:00
21 lines
390 B
PHP
21 lines
390 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace Psl\Tests\SecureRandom;
|
|
|
|
use PHPUnit\Framework\TestCase;
|
|
use Psl\SecureRandom;
|
|
|
|
class FloatTest extends TestCase
|
|
{
|
|
public function testFloat(): void
|
|
{
|
|
$random = SecureRandom\float();
|
|
|
|
self::assertIsFloat($random);
|
|
self::assertGreaterThanOrEqual(0, $random);
|
|
self::assertLessThanOrEqual(1, $random);
|
|
}
|
|
}
|