Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 17f75f1

Browse files
committedApr 26, 2023
handle stupid Stupid STUPID whitespace changes in timestamps
ICU 72 is the worst ICU ever. EVER. When is whitespace not actually whitespace? When it's narrow no-break space whitespace. So so unamusing. See also: nodejs/node#46123
1 parent 5696e76 commit 17f75f1

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed
 

‎util/tests/dateUtils-test.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,11 @@ describe('Date Utilities', () => {
6464
describe('get locale time format - en-US', () => {
6565
let timeFormat;
6666
beforeEach(async () => {
67-
timeFormat = getLocalizedTimeFormatInfo('en-US'); // eslint-disable-line
67+
timeFormat = getLocalizedTimeFormatInfo('en-US');
68+
69+
// Oh ICU 72, how do I hate thee? Let me count the ways.
70+
// https://github.com/nodejs/node/issues/46123
71+
timeFormat.timeFormat = timeFormat.timeFormat.replaceAll('\u202f', ' ');
6872
});
6973

7074
it('returns the time format according to the passed locale', () => {

0 commit comments

Comments
 (0)
Please sign in to comment.