Skip to content
This repository has been archived by the owner on Jan 13, 2024. It is now read-only.

Skip pnpm tests when nodeversion is < 12 #1122

Merged
Merged
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
6 changes: 6 additions & 0 deletions test/test-10-pnpm/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ const path = require('path');
const assert = require('assert');
const utils = require('../utils.js');

// ignore this test if nodejs <= 10 , as recent version of PNPM do not support nodejs=10
const MAJOR_VERSION = parseInt(process.version.match(/v([0-9]+)/)[1], 10);
if (MAJOR_VERSION < 12) {
return;
}

assert(__dirname === process.cwd());

const target = process.argv[2] || 'host';
Expand Down
6 changes: 6 additions & 0 deletions test/test-11-pnpm/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ const path = require('path');
const assert = require('assert');
const utils = require('../utils.js');

// ignore this test if nodejs <= 10 , as recent version of PNPM do not support nodejs=10
const MAJOR_VERSION = parseInt(process.version.match(/v([0-9]+)/)[1], 10);
if (MAJOR_VERSION < 12) {
return;
}

console.log(__dirname, process.cwd());
assert(__dirname === process.cwd());

Expand Down