mirror of
https://github.com/knex/knex.git
synced 2025-09-27 00:54:03 +00:00
Fixes build issue related to Node.js 14 (#4078)
Co-authored-by: Jamie Peabody <jpeabody@axway.com>
This commit is contained in:
parent
80355e4850
commit
162cf2ebcf
@ -162,8 +162,10 @@ const fixture = [
|
|||||||
knexArgs: ['migrate:latest', isNode10 && `--esm`],
|
knexArgs: ['migrate:latest', isNode10 && `--esm`],
|
||||||
expectedErrorMessage: isNode10
|
expectedErrorMessage: isNode10
|
||||||
? 'Error: Cannot load module from .mjs'
|
? 'Error: Cannot load module from .mjs'
|
||||||
: semver.gte(process.version, 'v14.13.0')
|
: semver.eq(process.version, 'v14.13.0')
|
||||||
? 'Unexpected export statement in CJS module'
|
? 'Unexpected export statement in CJS module'
|
||||||
|
: semver.gte(process.version, 'v14.14.0')
|
||||||
|
? 'Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension.'
|
||||||
: "Unexpected token 'export'",
|
: "Unexpected token 'export'",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -179,8 +181,10 @@ const fixture = [
|
|||||||
knexArgs: ['migrate:latest', isNode10 && `--esm`],
|
knexArgs: ['migrate:latest', isNode10 && `--esm`],
|
||||||
expectedErrorMessage: isNode10
|
expectedErrorMessage: isNode10
|
||||||
? 'Error: Cannot load module from .mjs'
|
? 'Error: Cannot load module from .mjs'
|
||||||
: semver.gte(process.version, 'v14.13.0')
|
: semver.eq(process.version, 'v14.13.0')
|
||||||
? 'Unexpected export statement in CJS module'
|
? 'Unexpected export statement in CJS module'
|
||||||
|
: semver.gte(process.version, 'v14.14.0')
|
||||||
|
? 'Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension.'
|
||||||
: "Unexpected token 'export'",
|
: "Unexpected token 'export'",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user