Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions test/parallel/test-intl.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
'use strict';
const common = require('../common');
const assert = require('assert');
const { execFile } = require('child_process');

// Does node think that i18n was enabled?
let enablei18n = process.config.variables.v8_enable_i18n_support;
Expand Down Expand Up @@ -125,4 +126,14 @@ if (!common.hasIntl) {
assert.strictEqual(coll.compare('Bluebird', 'bluebird'), 0);
// `ffi` ligature (contraction)
assert.strictEqual(coll.compare('\ufb03', 'ffi'), 0);
{
// Regression test for https://github.com/nodejs/node/issues/27418
const env = { ...process.env, LC_ALL: 'fr@EURO' };
execFile(
process.execPath,
['-p', 'new Intl.NumberFormat().resolvedOptions().locale'],
{ env },
common.mustCall((e) => assert.ifError(e))
);
}
}
Loading