From 27d4447d24a7351c340921552d0595d7db57e39a Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Tue, 18 Sep 2018 12:56:35 -0700 Subject: [PATCH] test: remove common.hasSmallICU common.hasSmallICU is used in only one test and is a one-liner. Move into the test where it is used to chip away at the `common` monolith. --- test/common/README.md | 5 ----- test/common/index.js | 4 +--- test/parallel/test-icu-data-dir.js | 4 +++- 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/test/common/README.md b/test/common/README.md index 0b3a7e9201e4f6..08687547825b43 100644 --- a/test/common/README.md +++ b/test/common/README.md @@ -158,11 +158,6 @@ Indicates `hasCrypto` and `crypto` with fips. Indicates if [internationalization] is supported. -### hasSmallICU -* [<boolean>] - -Indicates `hasIntl` and `small-icu` are supported. - ### hasIPv6 * [<boolean>] diff --git a/test/common/index.js b/test/common/index.js index f0f849e6afbacf..3741211bd3d69c 100644 --- a/test/common/index.js +++ b/test/common/index.js @@ -32,8 +32,7 @@ const { fixturesDir } = require('./fixtures'); const tmpdir = require('./tmpdir'); const { bits, - hasIntl, - hasSmallICU + hasIntl } = process.binding('config'); const noop = () => {}; @@ -715,7 +714,6 @@ module.exports = { hasIntl, hasCrypto, hasIPv6, - hasSmallICU, hasMultiLocalhost, isAIX, isAlive, diff --git a/test/parallel/test-icu-data-dir.js b/test/parallel/test-icu-data-dir.js index 800e20c48bab03..47c955bc740fb3 100644 --- a/test/parallel/test-icu-data-dir.js +++ b/test/parallel/test-icu-data-dir.js @@ -1,7 +1,9 @@ 'use strict'; const common = require('../common'); const os = require('os'); -if (!(common.hasIntl && common.hasSmallICU)) + +const { hasSmallICU } = process.binding('config'); +if (!(common.hasIntl && hasSmallICU)) common.skip('missing Intl'); const assert = require('assert');