Make WordPress Core

Opened 11 years ago

Closed 11 years ago

#26345 closed defect (bug) (fixed)

Failure in Tests_Post_Query::test_meta_query_decimal_results()

Reported by: sergeybiryukov's profile SergeyBiryukov Owned by: sergeybiryukov's profile SergeyBiryukov
Milestone: 3.8 Priority: normal
Severity: normal Version:
Component: Unit Tests Keywords:
Focuses: Cc:

Description

The test sometimes fails due to different order of items in the array:

1) Tests_Post_Query::test_meta_query_decimal_results
Failed asserting that two arrays are equal.
--- Expected
+++ Actual
@@ @@
 Array (
-    0 => 3
-    1 => 4
-    2 => 5
+    0 => 5
+    1 => 3
+    2 => 4
 )

Since we don't specify an order there, assertEqualSets() should be used instead of direct array comparison.

Change History (1)

#1 @SergeyBiryukov
11 years ago

  • Owner set to SergeyBiryukov
  • Resolution set to fixed
  • Status changed from new to closed

In 26490:

Use assertEqualSets() instead of direct array comparison.

fixes #26345

Note: See TracTickets for help on using tickets.