From a75ae4f556af60ea9e9c4a2d2d971c5abe7b5628 Mon Sep 17 00:00:00 2001 From: Jonathan Vollebregt Date: Mon, 7 Nov 2022 18:44:20 +0100 Subject: [PATCH] testGetIdeLink: Prevent errors with random byte invalid codepoints --- tests/KintTest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/KintTest.php b/tests/KintTest.php index 7a78467c6..3c180889f 100644 --- a/tests/KintTest.php +++ b/tests/KintTest.php @@ -992,7 +992,7 @@ public function testGetIdeLink() { Kint::$file_link_format = '%f:%l'; - $file = \random_bytes(32); + $file = \bin2hex(\random_bytes(16)); $line = \random_int(1, PHP_INT_MAX); $this->assertSame(''.$file.':'.$line.'', Kint::getIdeLink($file, $line));