I have followed the instructions here https://github.com/wallabyjs/ngCliWebpackSample to get an example angular-cli app running with wallabyjs.
I can run the tests via 'npm run test' and all works fine with the 3 tests included passing.
However, I get the following error if I run wallabyjs:
AppComponent should render title in a h1 tag [16 ms]
Failed: No provider for TestingCompilerFactory!
at Object.<anonymous> src/app/app.component.spec.ts:9:4
Failed: No provider for TestingCompilerFactory!
at Object.<anonymous> src/app/app.component.spec.ts:29:4
AppComponent should have as title 'app' [14 ms]
Failed: No provider for TestingCompilerFactory!
at Object.<anonymous> src/app/app.component.spec.ts:9:4
Failed: No provider for TestingCompilerFactory!
at Object.<anonymous> src/app/app.component.spec.ts:23:4
AppComponent should create the app [9 ms]
Failed: No provider for TestingCompilerFactory!
at Object.<anonymous> src/app/app.component.spec.ts:9:4
Failed: No provider for TestingCompilerFactory!
at Object.<anonymous> src/app/app.component.spec.ts:17:4
..I've npm installed and installed the latest webpack, electron etc. globally.
Related
I am trying to setup Cypress in my laptop, but I get this error when I try to execute the example tests. I tried to clear the cypress cache and reinstall cypress, but got the same error. here is screen shot of what syntax error I receive when I hit "npm run test".
This is what I get in the terminal after I hit "npm run test"
C:\Users\u46827\AppData\Local\Cypress\Cache\10.7.0\Cypress\resources\app\node_modules\#packages\server\lib\plugins\child\run_plugins.js:40
invoke = (eventId, args = []) => {
SyntaxError: Unexpected token =
at new Script (vm.js:79:7)
at createScript (vm.js:251:10)
at Object.runInThisContext (vm.js:303:10)
at Module._compile (internal/modules/cjs/loader.js:656:28)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:699:10)
at Module.load (internal/modules/cjs/loader.js:598:32)
at tryModuleLoad (internal/modules/cjs/loader.js:537:12)
at Function.Module._load (internal/modules/cjs/loader.js:529:3)
at Module.require (internal/modules/cjs/loader.js:636:17)
at require (internal/modules/cjs/helpers.js:20:18)
at Object.<anonymous> (C:\Users\u46827\AppData\Local\Cypress\Cache\10.7.0\Cypress\resources\app\node_modules\#packages\server\lib\plugins\child\run_require_async_child.js:6:24)
at Module._compile (internal/modules/cjs/loader.js:688:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:699:10)
at Module.load (internal/modules/cjs/loader.js:598:32)
at tryModuleLoad (internal/modules/cjs/loader.js:537:12)
at Function.Module._load (internal/modules/cjs/loader.js:529:3)
[3544:0904/215759.289:ERROR:dns_config_service.cc(278)] DNS config watch failed.
Please open screenshot here
I found the issue. My node version was old. I updated it to 16
I'm looking to create my own external adapter. I pulled the external adapter repo and set it up with yarn per the README. However, when I try running cd packages/sources/coingecko && yarn start within any of the adapter directories, I get the following error:
/Users/jvilla/Documents/GitHub/external-adapters-js/packages/core/bootstrap/dist/lib/cache/index.js:73
if (!context?.cache?.instance)
^
SyntaxError: Unexpected token '.'
at wrapSafe (internal/modules/cjs/loader.js:1053:16)
at Module._compile (internal/modules/cjs/loader.js:1101:27)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
at Module.load (internal/modules/cjs/loader.js:985:32)
at Function.external_module_.Module._load (/Users/jvilla/Documents/GitHub/external-adapters-js/.pnp.cjs:42492:14)
at Module.require (internal/modules/cjs/loader.js:1025:19)
at require (internal/modules/cjs/helpers.js:72:18)
at Object.<anonymous> (/Users/jvilla/Documents/GitHub/external-adapters-js/packages/core/bootstrap/dist/index.js:6:17)
at Module._compile (internal/modules/cjs/loader.js:1137:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
The README mentions that some require environmental variables, but I don't see anything mentioned in coingecko and I'm not having any luck with the other adapters either.
Thanks to help in the Discord, I was able to resolve my issue. I was using an old version of node and needed to upgrade! The separate, but related, Chainlink Node Operator repo README has Node v12 hardcoded in its setup process, which won't work when running the External Adapter repo.
Error: Cannot find module '.'
Require stack:
- /codebuild/output/src309915592/src/node_modules/.bin/lerna
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:831:15)
at Function.Module._load (internal/modules/cjs/loader.js:687:27)
at Module.require (internal/modules/cjs/loader.js:903:19)
at require (internal/modules/cjs/helpers.js:74:18)
at Object.<anonymous> (/codebuild/output/src309915592/src/node_modules/.bin/lerna:11:3)
at Module._compile (internal/modules/cjs/loader.js:1015:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1035:10)
at Module.load (internal/modules/cjs/loader.js:879:32)
at Function.Module._load (internal/modules/cjs/loader.js:724:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
code: 'MODULE_NOT_FOUND',
requireStack: [ '/codebuild/output/src309915592/src/node_modules/.bin/lerna' ]
}
I get this error on running the test command:
lerna run --stream test --parallel
Also, tried with
lerna run --stream test --parallel --scope tenant-registration-service
In the services, test script looks like,
"test": "serverless-bundle test --verbose --coverage",
I installed Lerna globally in the pipeline. How do I debug this? What module is it not able to find? It looks like it already has lerna installed which it should.
npm run test command runs just fine on the local system.
I created an asp.net core 2.0 project via
dotnet new reactredux -n sample
then I imported a new module named "react-bootstrap" via npm install
npm install --save #types/react-bootstrap
everything is good so far, but if I try to run this project on my local.
I got this error
An unhandled exception occurred while processing the request.
NodeInvocationException: Prerendering failed because of error: Error: Cannot find module "react-bootstrap"
at Object.<anonymous> (e:\git\Sample\ClientApp\dist\main-server.js:883:7)
at __webpack_require__ (e:\git\Sample\ClientApp\dist\main-server.js:20:30)
at Object.<anonymous> (e:\git\Sample\ClientApp\dist\main-server.js:327:84)
at __webpack_require__ (e:\git\Sample\ClientApp\dist\main-server.js:20:30)
at Object.<anonymous> (e:\git\DotNetCoreFans\ClientApp\dist\main-server.js:384:66)
at __webpack_require__ (e:\git\Sample\ClientApp\dist\main-server.js:20:30)
at e:\git\Sample\ClientApp\dist\main-server.js:66:18
at Object.<anonymous> (e:\git\Sample\ClientApp\dist\main-server.js:69:10)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
Current directory is: e:\git\Sample
Does anyone how to fix it?
Atom Editor can be found here: https://atom.io/
Discourse thread about this issue here: http://discuss.atom.io/t/application-run-all-specs-fail-to-run/7541
I am running: MBP (OS X 10.9.2) with Atom 0.84.0 and Node 0.10.26.
When I do View > Developer > Run atom specs
- Nothing happens, no window opens, inspector doesn't open
When I do
apm develop vim-mode
cd ~/github/vim-mode
atom .
View > Developer > Run package specs
- Nothing happens, no window opens, inspector doesn't open
I then tried
~/github/vim-mode $ apm test
[764:0409/142738:INFO:renderer_main.cc(227)] Renderer process started
No window opened, however another Atom program launched with a menu containing "Atom > [Reload, Close, Toggle, Quit]"
After pressing Quit, the terminal said "Tests passed". None of the other buttons worked
~/github/vim-mode $ apm test
[645:0409/141838:INFO:renderer_main.cc(227)] Renderer process started
Tests passed
I don't think they actually passed, "Tests passed" only showed up after quitting the window
I then tried atom -d
And an identical program started with no window
I then tried running tests via another way
~/github/vim-mode $ atom -t
[833:0409/143232:INFO:renderer_main.cc(227)] Renderer process started
[831:0409/143236:INFO:CONSOLE(27)] "Error: Cannot find module '../lib/ui-watcher.coffee'
at Function.Module._resolveFilename (module.js:337:15)
at Function.Module._load (module.js:279:25)
at Module.require (module.js:363:17)
at require (module.js:379:17)
at Object.<anonymous> (/Applications/Atom.app/Contents/Resources/app/node_modules/dev-live-reload/spec/ui-watcher-spec.js:8:15)
at Object.<anonymous> (/Applications/Atom.app/Contents/Resources/app/node_modules/dev-live-reload/spec/ui-watcher-spec.js:185:4)
at Module._compile (module.js:455:26)
at Object.Module._extensions..js (module.js:473:10)
at Module.load (/Applications/Atom.app/Contents/Resources/app/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at Function.Module._load (module.js:311:12)
at Module.require (module.js:363:17)
at require (module.js:379:17)
at requireSpecs (/Applications/Atom.app/Contents/Resources/app/spec/spec-suite.coffee:9:5)
at runAllSpecs (/Applications/Atom.app/Contents/Resources/app/spec/spec-suite.coffee:47:3)
at Object.<anonymous> (/Applications/Atom.app/Contents/Resources/app/spec/spec-suite.coffee:58:3)
at Object.<anonymous> (/Applications/Atom.app/Contents/Resources/app/spec/spec-suite.coffee:1:1)
at Module._compile (module.js:455:26)
at Object.requireCoffeeScript [as .coffee] (/Applications/Atom.app/Contents/Resources/app/src/coffee-cache.js:64:19)
at Module.load (/Applications/Atom.app/Contents/Resources/app/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at Function.Module._load (module.js:311:12)
at Module.require (module.js:363:17)
at require (module.js:379:17)
at module.exports.runSpecSuite (/Applications/Atom.app/Contents/Resources/app/spec/jasmine-helper.coffee:30:3)
at Object.<anonymous> (/Applications/Atom.app/Contents/Resources/app/spec/spec-bootstrap.coffee:24:3)
at Object.<anonymous> (/Applications/Atom.app/Contents/Resources/app/spec/spec-bootstrap.coffee:2:1)
at Module._compile (module.js:455:26)
at Object.requireCoffeeScript [as .coffee] (/Applications/Atom.app/Contents/Resources/app/src/coffee-cache.js:64:19)
at Module.load (/Applications/Atom.app/Contents/Resources/app/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at Function.Module._load (module.js:311:12)
at Module.require (module.js:363:17)
at require (module.js:379:17)
at window.onload (file:///Applications/Atom.app/Contents/Resources/app/static/index.js:20:5)
", source: /Applications/Atom.app/Contents/Resources/app/spec/spec-bootstrap.coffee (27)
This issue is not relevant any longer, problem solved after reinstallation.