diff --git a/tests/StringsTest.php b/tests/StringsTest.php index 1b9c666..e982e18 100644 --- a/tests/StringsTest.php +++ b/tests/StringsTest.php @@ -58,9 +58,10 @@ }); test('test random() method', function (): void { - $this->assertNotEquals(Strings::create()->random(0), Strings::create()->random(0)); + $this->assertTrue(is_string(Strings::create()->random(0)->toString())); + $this->assertStringContainsString(Strings::create()->random(0)->toString(), '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'); $this->assertNotEquals(Strings::create()->random(), Strings::create()->random()); - $this->assertNotEquals(Strings::create()->random(10), Strings::create()->random(10)); + $this->assertNotEquals(Strings::create()->random(100), Strings::create()->random(100)); $this->assertNotEquals(Strings::create()->random(10, '0123456789'), Strings::create()->random(10, '0123456789')); $this->assertEquals(10, Strings::create(Strings::create()->random(10, '0123456789'))->length()); });