Webdriverio: wdio.conf.ejs não criado

Criado em 29 jul. 2017  ·  4Comentários  ·  Fonte: webdriverio/webdriverio

O problema

Eu experimentei exatamente o mesmo problema que # 1568 que foi fechado na época, mas relatado novamente por aztack .

Quando tento configurar o Webdriver IO após instalá-lo, recebo um erro logo após passar pela interface de perguntas:

=========================
WDIO Configuration Helper
=========================

? Where do you want to execute your tests? On my local machine
? Which framework do you want to use? mocha
? Shall I install the framework adapter for you? Yes
? Where are your test specs located? ./test/*.js
? Which reporter do you want to use?  spec - https://github.com/webdriverio/wdio-spec-reporter
? Shall I install the reporter library for you? Yes
? Do you want to add a service to your test setup?  selenium-standalone - https://github.com/webdriverio/wdio-selenium-standalone
-service
? Shall I install the services for you? Yes
? Level of logging verbosity command
? In which directory should screenshots gets saved if a command fails? ./errorShots/
? What is the base url? http://localhost

Installing wdio packages:

Packages installed successfully, creating configuration file...
fs.js:651
  return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode);
                 ^

Error: ENOENT: no such file or directory, open '/Users/sarahdayan/Projets/communitytalk.com/node_modules/webdriverio/build/lib/helpers/wdio.conf.ejs'
    at Object.fs.openSync (fs.js:651:18)
    at Object.fs.readFileSync (fs.js:553:33)
    at renderConfigurationFile (/Users/sarahdayan/Projets/communitytalk.com/node_modules/webdriverio/build/lib/cli.js:292:28)
    at /Users/sarahdayan/Projets/communitytalk.com/node_modules/webdriverio/build/lib/cli.js:282:17
    at /Users/sarahdayan/Projets/communitytalk.com/node_modules/npm-install-package/index.js:31:5
    at ChildProcess.exithandler (child_process.js:262:7)
    at emitTwo (events.js:125:13)
    at ChildProcess.emit (events.js:213:7)
    at maybeClose (internal/child_process.js:897:16)
    at Socket.stream.socket.on (internal/child_process.js:340:11)
npm ERR! Test failed.  See above for more details.

Ambiente

Detalhe

Consegui contornar o problema dizendo não à instalação do framework e pulando a seleção de um repórter e adicionando um serviço à minha configuração de teste:

? Shall I install the framework adapter for you? No
? Which reporter do you want to use?
? Do you want to add a service to your test setup?

Eu os instalei e editei o wdio.conf.js manualmente, mas isso não é o ideal.

Desde já, obrigado!

Comentários muito úteis

Eu me deparei com o mesmo problema: nó 8.2.1 + fio não funciona v0.27.5, nó 8.2.1 + npm 5.3.0 funciona, nó 7.10.1 + fio funciona. Alguma ideia de onde pode estar o problema?

=========================
WDIO Configuration Helper
=========================

? Where do you want to execute your tests? On my local machine
? Which framework do you want to use? cucumber
? Shall I install the framework adapter for you? Yes
? Where are your feature files located? ./features/**/*.feature
? Where are your step definitions located? ./features/step-definitions
? Which reporter do you want to use?  spec - https://github.com/webdriverio/wdio-spec-reporter
? Shall I install the reporter library for you? Yes
? Do you want to add a service to your test setup?  selenium-standalone - https://github.com/webdriverio/wdio-selenium-standalone-service,  phantomjs - https://github.com/cognitom/wdio-phantomjs-serv
ice
? Shall I install the services for you? Yes
? Level of logging verbosity silent
? In which directory should screenshots gets saved if a command fails? ./errorShots/
? What is the base url? http://localhost

o erro é o mesmo

Todos 4 comentários

Você pode tentar com o Node v7.x?

@christian-bromann Apenas tentei com várias versões do Node (v6.11.1, v7.0.0, v8.1.3, v8.2.1) e estranhamente, tudo passou 😶 Talvez algo estivesse errado com minha cópia local do Node quando tentei pela primeira vez Tempo.

Acho que qualquer pessoa com o mesmo problema precisaria apenas reinstalar ou atualizar o Node e isso deve fazer isso.

Estou recebendo o mesmo problema - usando o nó v8.1.2

Eu me deparei com o mesmo problema: nó 8.2.1 + fio não funciona v0.27.5, nó 8.2.1 + npm 5.3.0 funciona, nó 7.10.1 + fio funciona. Alguma ideia de onde pode estar o problema?

=========================
WDIO Configuration Helper
=========================

? Where do you want to execute your tests? On my local machine
? Which framework do you want to use? cucumber
? Shall I install the framework adapter for you? Yes
? Where are your feature files located? ./features/**/*.feature
? Where are your step definitions located? ./features/step-definitions
? Which reporter do you want to use?  spec - https://github.com/webdriverio/wdio-spec-reporter
? Shall I install the reporter library for you? Yes
? Do you want to add a service to your test setup?  selenium-standalone - https://github.com/webdriverio/wdio-selenium-standalone-service,  phantomjs - https://github.com/cognitom/wdio-phantomjs-serv
ice
? Shall I install the services for you? Yes
? Level of logging verbosity silent
? In which directory should screenshots gets saved if a command fails? ./errorShots/
? What is the base url? http://localhost

o erro é o mesmo

Esta página foi útil?
0 / 5 - 0 avaliações

Questões relacionadas

peterjwest picture peterjwest  ·  4Comentários

davidsoderberg picture davidsoderberg  ·  4Comentários

kiraLinden picture kiraLinden  ·  3Comentários

Pylipala picture Pylipala  ·  4Comentários

pfluegs picture pfluegs  ·  4Comentários