mirror of
https://github.com/nodejs/node.git
synced 2024-12-01 16:10:02 +01:00
6a1275dfec
In 9d522225e7
the indirect "http_parser.h"
include was removed, which made `NODE_STRINGIFY()` fail silently for the
http parser version in `process.versions`.
PR-URL: https://github.com/nodejs/node/pull/12464
Fixes: https://github.com/nodejs/node/issues/12463
Ref: https://github.com/nodejs/node/pull/12366
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Alexey Orlenko <eaglexrlnk@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
31 lines
951 B
JavaScript
31 lines
951 B
JavaScript
'use strict';
|
|
const common = require('../common');
|
|
const assert = require('assert');
|
|
|
|
const expected_keys = ['ares', 'http_parser', 'modules', 'node',
|
|
'uv', 'v8', 'zlib'];
|
|
|
|
if (common.hasCrypto) {
|
|
expected_keys.push('openssl');
|
|
}
|
|
|
|
if (common.hasIntl) {
|
|
expected_keys.push('icu');
|
|
expected_keys.push('cldr');
|
|
expected_keys.push('tz');
|
|
expected_keys.push('unicode');
|
|
}
|
|
|
|
expected_keys.sort();
|
|
const actual_keys = Object.keys(process.versions).sort();
|
|
|
|
assert.deepStrictEqual(actual_keys, expected_keys);
|
|
|
|
assert(/^\d+\.\d+\.\d+(-.*)?$/.test(process.versions.ares));
|
|
assert(/^\d+\.\d+\.\d+(-.*)?$/.test(process.versions.http_parser));
|
|
assert(/^\d+\.\d+\.\d+(-.*)?$/.test(process.versions.node));
|
|
assert(/^\d+\.\d+\.\d+(-.*)?$/.test(process.versions.uv));
|
|
assert(/^\d+\.\d+\.\d+(-.*)?$/.test(process.versions.zlib));
|
|
assert(/^\d+\.\d+\.\d+\.\d+$/.test(process.versions.v8));
|
|
assert(/^\d+$/.test(process.versions.modules));
|