question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error after passed test

See original GitHub issue

What are you trying to achieve?

Run tests without errors in console

What do you get instead?

“UnhandledPromiseRejectionWarning: Error: Execution context was destroyed, most likely because of a navigation.” after almost every successful test.

Provide console output if related. Use --verbose mode for more details.

Emitted | test.after ([object Object]) (node:29144) UnhandledPromiseRejectionWarning: Error: Navigation failed because browser has disconnected! at Connection.NavigatorWatcher._eventListeners.helper.addEventListener (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\FrameManager.js:1146:117) at emitNone (events.js:111:20) at Connection.emit (events.js:208:7) at Connection._onClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\Connection.js:123:10) at WebSocketTransport._ws.addEventListener.event (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\WebSocketTransport.js:45:22) at WebSocket.onClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\ws\lib\event-target.js:124:16) at emitTwo (events.js:126:13) at WebSocket.emit (events.js:214:7) at WebSocket.emitClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\ws\lib\websocket.js:172:10) at Socket.socketOnClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\ws\lib\websocket.js:781:15) at emitOne (events.js:116:13) at Socket.emit (events.js:211:7) at TCP._handle.close [as _onclose] (net.js:557:12) – ASYNC – at Frame.<anonymous> (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\helper.js:144:27) at Page.waitForNavigation (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\Page.js:599:49) at Page.<anonymous> (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\helper.js:145:23) at Puppeteer.waitForNavigation (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\codeceptjs\lib\helper\Puppeteer.js:1711:22) at Puppeteer.proceedClick (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\codeceptjs\lib\helper\Puppeteer.js:1804:15) at <anonymous> at process._tickCallback (internal/process/next_tick.js:188:7) (node:29144) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1) (node:29144) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. (node:29144) UnhandledPromiseRejectionWarning: Error: Navigation failed because browser has disconnected! at Connection.NavigatorWatcher._eventListeners.helper.addEventListener (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\FrameManager.js:1146:117) at emitNone (events.js:111:20) at Connection.emit (events.js:208:7) at Connection._onClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\Connection.js:123:10) at WebSocketTransport._ws.addEventListener.event (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\WebSocketTransport.js:45:22) at WebSocket.onClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\ws\lib\event-target.js:124:16) at emitTwo (events.js:126:13) at WebSocket.emit (events.js:214:7) at WebSocket.emitClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\ws\lib\websocket.js:172:10) at Socket.socketOnClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\ws\lib\websocket.js:781:15) at emitOne (events.js:116:13) at Socket.emit (events.js:211:7) at TCP._handle.close [as _onclose] (net.js:557:12) – ASYNC – at Frame.<anonymous> (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\helper.js:144:27) at Page.waitForNavigation (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\Page.js:599:49) at Page.<anonymous> (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\helper.js:145:23) at Puppeteer.waitForNavigation (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\codeceptjs\lib\helper\Puppeteer.js:1711:22) at Puppeteer.proceedClick (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\codeceptjs\lib\helper\Puppeteer.js:1804:15) at <anonymous> at process._tickCallback (internal/process/next_tick.js:188:7) (node:29144) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2) (node:29144) UnhandledPromiseRejectionWarning: Error: Navigation failed because browser has disconnected! at Connection.NavigatorWatcher._eventListeners.helper.addEventListener (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\FrameManager.js:1146:117) at emitNone (events.js:111:20) at Connection.emit (events.js:208:7) at Connection._onClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\Connection.js:123:10) at WebSocketTransport._ws.addEventListener.event (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\WebSocketTransport.js:45:22) at WebSocket.onClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\ws\lib\event-target.js:124:16) at emitTwo (events.js:126:13) at WebSocket.emit (events.js:214:7) at WebSocket.emitClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\ws\lib\websocket.js:172:10) at Socket.socketOnClose (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\ws\lib\websocket.js:781:15) at emitOne (events.js:116:13) at Socket.emit (events.js:211:7) at TCP._handle.close [as _onclose] (net.js:557:12) – ASYNC – at Frame.<anonymous> (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\helper.js:144:27) at Page.waitForNavigation (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\Page.js:599:49) at Page.<anonymous> (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\puppeteer\lib\helper.js:145:23) at Puppeteer.waitForNavigation (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\codeceptjs\lib\helper\Puppeteer.js:1711:22) at Puppeteer.proceedClick (C:\Users\eduard.lind\Documents\unfall.uitestswebsitedesktop\node_modules\codeceptjs\lib\helper\Puppeteer.js:1804:15) at <anonymous> at process._tickCallback (internal/process/next_tick.js:188:7) (node:29144) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 3) Emitted | suite.after ([object Object])

Details

  • CodeceptJS version: ~1.4.3
  • NodeJS Version: 8.11.2
  • Operating System: Windows 10
  • Puppeteer: 1.9.0
  • Configuration file:

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:6
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
eduard-lindcommented, Nov 6, 2018

This issue is gone with latest CodeceptJS 1.4.4

Not for me…still see it

1reaction
PeterNgTrcommented, Oct 29, 2018

This issue is gone with latest CodeceptJS 1.4.4

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error after passed test · Issue #1257 · codeceptjs ... - GitHub
What are you trying to achieve? Run tests without errors in console What do you get instead? "UnhandledPromiseRejectionWarning: Error: ...
Read more >
15 Silly Mistakes ("Automatic Fails") That Prevent You From ...
15 Silly Mistakes (“Automatic Fails”) That Prevent You From Passing Your DMV Test Today · 1. Rolling Stops · 2. Improper Lane Changing...
Read more >
Status "Pass with Error" for Test Run without Steps | Support
By Test Execution, the tester has found a bug and set the result to failed. Afterwards, the bug was reviewed. It was accepted...
Read more >
How many errors are allowed on the driving test? - Jerry
You are allowed 15 minor mistakes on your driving test. If you commit a serious error, however, you may be failed immediately.
Read more >
Jest test passed but get Error: connect ECONNREFUSED ...
When I'm trying to test I have the result pass but I get an error at the end. Here's the result: PASS test/controllers/user.controller.test.ts ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found