blob: 8d2cf8f3f3e6c5f454cb7b6b9973832ad432242b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
'use strict';
const common = require('../common');
const assert = require('assert');
const { Worker } = require('worker_threads');
const worker = new Worker('./does-not-exist.js', {
execArgv: ['--experimental-modules'],
});
worker.on('error', common.mustCall((err) => {
// eslint-disable-next-line node-core/no-unescaped-regexp-dot
assert(/Cannot find module .+does-not-exist.js/.test(err.message), err);
}));
|