0
0
mirror of https://github.com/nodejs/node.git synced 2024-11-21 21:19:50 +01:00
nodejs/test/parallel/test-corepack-version.js
Maël Nison 46598b88bf
deps: add corepack
Corepack provides shims for Yarn and pnpm in order to soften the
developer experience when working on Node projects.

Refs: https://github.com/nodejs/node/issues/15244
Refs: https://github.com/nodejs/TSC/issues/904

PR-URL: https://github.com/nodejs/node/pull/39608
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
2021-08-25 07:55:32 -07:00

19 lines
366 B
JavaScript

'use strict';
require('../common');
const path = require('path');
const assert = require('assert');
const corepackPathPackageJson = path.resolve(
__dirname,
'..',
'..',
'deps',
'corepack',
'package.json'
);
const pkg = require(corepackPathPackageJson);
assert(pkg.version.match(/^\d+\.\d+\.\d+$/),
`unexpected version number: ${pkg.version}`);