From de6b82947d0f3f6988be9906b0ac0c2faa052f15 Mon Sep 17 00:00:00 2001 From: Jaime Perez Crespo <jaime.perez@uninett.no> Date: Fri, 26 Feb 2016 11:36:39 +0100 Subject: [PATCH] Move RandomTest to SimpleSAML\Test\Utils\RandomTest. --- tests/lib/SimpleSAML/Utils/RandomTest.php | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/tests/lib/SimpleSAML/Utils/RandomTest.php b/tests/lib/SimpleSAML/Utils/RandomTest.php index fe82f3894..9f2f6381b 100644 --- a/tests/lib/SimpleSAML/Utils/RandomTest.php +++ b/tests/lib/SimpleSAML/Utils/RandomTest.php @@ -1,18 +1,26 @@ <?php +namespace SimpleSAML\Test\Utils; + +use SimpleSAML\Utils\Random; /** * Tests for SimpleSAML\Utils\Random. */ -class RandomTest extends PHPUnit_Framework_TestCase +class RandomTest extends \PHPUnit_Framework_TestCase { + /** + * Test for SimpleSAML\Utils\Random::generateID(). + * + * @covers SimpleSAML\Utils\Random::generateID + */ public function testGenerateID() { // check that it always starts with an underscore - $this->assertStringStartsWith('_', SimpleSAML\Utils\Random::generateID()); + $this->assertStringStartsWith('_', Random::generateID()); // check the length - $this->assertEquals(SimpleSAML\Utils\Random::ID_LENGTH, strlen(SimpleSAML\Utils\Random::generateID())); + $this->assertEquals(Random::ID_LENGTH, strlen(Random::generateID())); } } -- GitLab