From 29f4c6ab5ff28e5822d0f1ba8941b6fa828e5115 Mon Sep 17 00:00:00 2001 From: mk-mxp <55182845+mk-mxp@users.noreply.github.com> Date: Sat, 25 Jan 2025 10:26:17 +0100 Subject: [PATCH] Ensure order independence --- exercises/practice/anagram/AnagramTest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exercises/practice/anagram/AnagramTest.php b/exercises/practice/anagram/AnagramTest.php index 970e25ec..6394ff43 100644 --- a/exercises/practice/anagram/AnagramTest.php +++ b/exercises/practice/anagram/AnagramTest.php @@ -84,7 +84,7 @@ public function testDoesNotDetectNonAnagramsWithIdenticalChecksum(): void */ public function testDetectsAnagramsCaseInsensitively(): void { - $this->assertEqualsCanonicalizing(['Carthorse'], detectAnagrams('Orchestra', ['cashregister', 'Carthorse', 'radishes'])); + $this->assertEqualsCanonicalizing(['Carthorse'], array_values(detectAnagrams('Orchestra', ['cashregister', 'Carthorse', 'radishes']))); } /**