kiwigrid / gherkin-testcafe

Run testcafe tests with gherkin syntax
MIT License
69 stars 2 forks source link

Google example fails on fresh install: Cannot find module 'cucumber/lib/models/data_table' #39

Closed leegee closed 5 years ago

leegee commented 5 years ago

On a fresh install following the documentation and running the provided Google example:

Lees-MacBook-Pro:app lee$ npm i --save-dev cucumber
npm WARN gherkin-testcafe@2.3.2 requires a peer of cucumber@^5.1.0 but none is installed. You must install peer dependencies yourself.

+ cucumber@1.3.3
updated 1 package and audited 16228 packages in 7.225s
Lees-MacBook-Pro:app lee$ gherkin-testcafe chrome e2e/**/*.js e2e/**/*.feature
internal/modules/cjs/loader.js:626
    throw err;
    ^

Error: Cannot find module 'cucumber/lib/models/data_table'
Require stack:
- /Users/lee/src/egs/app-lsrp/app/node_modules/gherkin-testcafe/src/compiler.js
- /Users/lee/src/egs/app-lsrp/app/node_modules/gherkin-testcafe/src/rewire-compiler.js
- /Users/lee/src/egs/app-lsrp/app/node_modules/gherkin-testcafe/src/cli.js
- /Users/lee/src/egs/app-lsrp/app/node_modules/gherkin-testcafe/main.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:623:15)
    at Function.Module._load (internal/modules/cjs/loader.js:527:27)
    at Module.require (internal/modules/cjs/loader.js:681:19)
    at require (internal/modules/cjs/helpers.js:16:16)
    at Object.<anonymous> (/Users/lee/src/egs/app-lsrp/app/node_modules/gherkin-testcafe/src/compiler.js:7:19)
    at Module._compile (internal/modules/cjs/loader.js:774:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:785:10)
    at Module.load (internal/modules/cjs/loader.js:641:32)
    at Function.Module._load (internal/modules/cjs/loader.js:556:12)
    at Module.require (internal/modules/cjs/loader.js:681:19) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    '/Users/lee/src/egs/app-lsrp/app/node_modules/gherkin-testcafe/src/compiler.js',
    '/Users/lee/src/egs/app-lsrp/app/node_modules/gherkin-testcafe/src/rewire-compiler.js',
    '/Users/lee/src/egs/app-lsrp/app/node_modules/gherkin-testcafe/src/cli.js',
    '/Users/lee/src/egs/app-lsrp/app/node_modules/gherkin-testcafe/main.js'
  ]
}
Lees-MacBook-Pro:app lee$
Lees-MacBook-Pro:app lee$ node -v
v12.4.0
Lees-MacBook-Pro:app lee$ npm -v
6.9.0
Lees-MacBook-Pro:app lee$
Lukas-Kullmann commented 5 years ago

Hey @leegee,

the log says, that you do not have installed cucumber. You have to install cucumber in addition to gherkin-testcafe (see readme's installation section).

Please verify that cucumber is installed and try again.

leegee commented 5 years ago

Not at a pc atm but didn't the console output show me installing cucumber? TIA

On Thu, Jun 27, 2019, 15:11 Lukas notifications@github.com wrote:

Hey @leegee https://github.com/leegee,

the log says, that you do not have installed cucumber. You have to install cucumber in addition to gherkin-testcafe (see readme's installation section https://github.com/kiwigrid/gherkin-testcafe#installation).

Please verify that cucumber is installed and try again.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/kiwigrid/gherkin-testcafe/issues/39?email_source=notifications&email_token=AAD5GMCNVXFDGFOGCPSJJYTP4TC7LA5CNFSM4H34ELFKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODYXHXPI#issuecomment-506362813, or mute the thread https://github.com/notifications/unsubscribe-auth/AAD5GMAI7IY43BG5VRBFAN3P4TC7LANCNFSM4H34ELFA .

Lukas-Kullmann commented 5 years ago

True. But your console also says, that it installed cucumber in version 1.3.3. You need cucumber 5.1.

leegee commented 5 years ago

Ah, thank you!

npm WARN gherkin-testcafe@2.3.2 requires a peer of cucumber@^5.1.0 but none is installed. You must install peer dependencies yourself.

leegee commented 5 years ago

Forked and made a PR to fix that, but despite making the PR on this repo, it seems to have been created against the original repo ('seitgeist')