Test customer report filtering without sorting

The report doesn't seem to sort. So the specs don't expect that either
now. These specs were flaky before, depending on the random order in the
database query result.
This commit is contained in:
Maikel Linke
2023-10-09 12:05:24 +11:00
parent 90c25d604b
commit 228f69f13e

View File

@@ -266,7 +266,7 @@ module Reporting
completed_at_lt: 1.day.after(o2.completed_at)
}
)
expect(subject.filter(orders)).to eq([o2, o3])
expect(subject.filter(orders)).to match_array [o2, o3]
end
it "when completed_at_lt param is missing" do
@@ -276,7 +276,7 @@ module Reporting
completed_at_lt: ""
}
)
expect(subject.filter(orders)).to eq([o1, o2])
expect(subject.filter(orders)).to match_array [o1, o2]
end
end