Skip to content

Commit

Permalink
Tests: Fix 31 December bug (#40781)
Browse files Browse the repository at this point in the history
* Use dates that should be valid for the life of the test

* Add changelog
  • Loading branch information
tbradsha authored Dec 31, 2024
1 parent b296ca1 commit 8d28f24
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fixed

Tests: Fix failure on 31 December.
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,9 @@ public function get_mock_products_data() {
'currency_code' => 'BRL',
'product_term' => 'month',
'sale_coupon' => (object) array(
'start_date' => gmdate( 'Y' ) . '-01-01',
'expires' => gmdate( 'Y' ) . '-12-31',
// Random dates (or are they?) so we always get the sale price.
'start_date' => '2003-05-27',
'expires' => '2063-04-05',
'discount' => 50,
),
),
Expand Down

0 comments on commit 8d28f24

Please sign in to comment.