diff --git a/changelog/fix-jest-timezone-nov-2022 b/changelog/fix-jest-timezone-nov-2022 new file mode 100644 index 00000000000..4f73f5cc6c2 --- /dev/null +++ b/changelog/fix-jest-timezone-nov-2022 @@ -0,0 +1,4 @@ +Significance: patch +Type: dev + + diff --git a/client/data/transactions/test/resolvers.js b/client/data/transactions/test/resolvers.js index 17ef3b88bf1..e68d8e7df23 100644 --- a/client/data/transactions/test/resolvers.js +++ b/client/data/transactions/test/resolvers.js @@ -43,7 +43,7 @@ describe( 'getTransactions resolver', () => { 'page=1&pagesize=25&sort=date&direction=desc' + '&match=all&date_before=2020-04-29%2003%3A59%3A59&date_after=2020-04-29%2004%3A00%3A00' + '&date_between%5B0%5D=2020-04-28%2004%3A00%3A00&date_between%5B1%5D=2020-04-30%2003%3A59%3A59&type_is=charge' + - '&type_is_not=dispute&loan_id_is=mock_flxln_id&deposit_id=mock_po_id&search=Test%20user&user_timezone=-04%3A00'; + '&type_is_not=dispute&loan_id_is=mock_flxln_id&deposit_id=mock_po_id&search=Test%20user&user_timezone=-05%3A00'; let generator = null; beforeEach( () => { @@ -89,7 +89,7 @@ describe( 'getTransactionsSummary resolver', () => { const expectedQueryString = 'match=all&date_before=2020-04-29%2003%3A59%3A59&date_after=2020-04-29%2004%3A00%3A00' + '&date_between%5B0%5D=2020-04-28%2004%3A00%3A00&date_between%5B1%5D=2020-04-30%2003%3A59%3A59&type_is=charge' + - '&type_is_not=dispute&loan_id_is=mock_flxln_id&deposit_id=mock_po_id&search=Test%20user&user_timezone=-04%3A00'; + '&type_is_not=dispute&loan_id_is=mock_flxln_id&deposit_id=mock_po_id&search=Test%20user&user_timezone=-05%3A00'; let generator = null; beforeEach( () => { diff --git a/client/transactions/list/test/index.tsx b/client/transactions/list/test/index.tsx index 6ae21c1993a..84e5cffc9ae 100644 --- a/client/transactions/list/test/index.tsx +++ b/client/transactions/list/test/index.tsx @@ -520,7 +520,7 @@ describe( 'Transactions list', () => { expect( mockApiFetch ).toHaveBeenCalledWith( { method: 'POST', path: - '/wc/v3/payments/transactions/download?user_email=mock%40example.com&user_timezone=-04%3A00', + '/wc/v3/payments/transactions/download?user_email=mock%40example.com&user_timezone=-05%3A00', } ); } ); } ); @@ -575,7 +575,7 @@ describe( 'Transactions list', () => { expect( mockApiFetch ).toHaveBeenCalledWith( { method: 'POST', path: - '/wc/v3/payments/transactions/download?user_email=mock%40example.com&deposit_id=po_mock&user_timezone=-04%3A00', + '/wc/v3/payments/transactions/download?user_email=mock%40example.com&deposit_id=po_mock&user_timezone=-05%3A00', } ); } ); } );