Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gulp test-coverage throws an error #5245

Closed
florin-nedelcu opened this issue May 15, 2020 · 4 comments
Closed

gulp test-coverage throws an error #5245

florin-nedelcu opened this issue May 15, 2020 · 4 comments

Comments

@florin-nedelcu
Copy link

Type of issue

Description

The command gulp test works fine and all tests are passing. When running test-coverage the following error occurs:
[15:34:25] Using gulpfile ~\Desktop\prebid\Prebid.js\gulpfile.js
[15:34:25] Starting 'test-coverage'...
[15:34:25] Starting 'clean'...
[15:34:25] Finished 'clean' after 168 ms
[15:34:25] Starting 'testCoverage'...
i 「wdm」:
i 「wdm」: Compiled successfully.

START:
i 「wdm」: Compiling...
i 「wdm」:
i 「wdm」: Compiled successfully.
15 05 2020 15:35:46.414:INFO [karma-server]: Karma v4.4.1 server started at http://0.0.0.0:9876/
15 05 2020 15:35:46.416:INFO [launcher]: Launching browsers ChromeHeadless with concurrency 5
15 05 2020 15:35:46.942:INFO [launcher]: Starting browser ChromeHeadless
15 05 2020 15:35:49.109:INFO [HeadlessChrome 81.0.4044 (Windows 10.0.0)]: Connected on socket -M8ziOESPCSLyKq8AAAA with id 87397791
15 05 2020 15:35:53.538:WARN [reporter]: SourceMap position not found for trace: Uncaught TypeError: Cannot read property 'f' of undefinedat http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:179:185055

TypeError: Cannot read property 'f' of undefined
at Object.getParameterByName (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:179:185055)
at Object. (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:248:55165)
at webpack_require (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:20:30)
at Object. (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:166:69)
at webpack_require (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:20:30)
at Object. (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:873:68)
at webpack_require (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:20:30)
at Object. (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:13301:74)
at webpack_require (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:20:30)
at Object. (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:34003:1)
15 05 2020 15:35:53.541:WARN [reporter]: SourceMap position not found for trace: Uncaught TypeError: Cannot read property 'f' of undefinedat http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:179:185055

TypeError: Cannot read property 'f' of undefined
at Object.getParameterByName (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:179:185055)
at Object. (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:248:55165)
at webpack_require (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:20:30)
at Object. (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:166:69)
at webpack_require (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:20:30)
at Object. (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:873:68)
at webpack_require (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:20:30)
at Object. (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:13301:74)
at webpack_require (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:20:30)
at Object. (http://localhost:9876/base/test/test_index.js?e9733d491ba8dd8e6ccd1b6ec57c2b43b90d0eb9:34003:1)
HeadlessChrome 81.0.4044 (Windows 10.0.0) ERROR
Uncaught TypeError: Cannot read property 'f' of undefined
at webpack:///src/utils.js:308:42 <- test/test_index.js:179:185055

TypeError: Cannot read property 'f' of undefined
at Object.getParameterByName (webpack:///src/utils.js:308:42 <- test/test_index.js:179:185055)
at Object. (webpack:///src/config.js:30:27 <- test/test_index.js:248:55165)
at webpack_require (webpack:///webpack/bootstrap%2067a68b5c76a10477dcfc:19:1 <- test/test_index.js:20:30)
at Object. (test/test_index.js:166:69)
at webpack_require (webpack:///webpack/bootstrap%2067a68b5c76a10477dcfc:19:1 <- test/test_index.js:20:30)
at Object. (test/test_index.js:873:68)
at webpack_require (webpack:///webpack/bootstrap%2067a68b5c76a10477dcfc:19:1 <- test/test_index.js:20:30)
at Object. (webpack:///test/mocks/adloaderStub.js:2:1 <- test/test_index.js:13301:74)
at webpack_require (webpack:///webpack/bootstrap%2067a68b5c76a10477dcfc:19:1 <- test/test_index.js:20:30)
at Object. (webpack:///test/test_index.js:2:1 <- test/test_index.js:34003:1)

Finished in 4.442 secs / 0 secs @ 15:35:53 GMT+0300 (GTB Daylight Time)

SUMMARY:
√ 0 tests completed
[15:35:53] 'testCoverage' errored after 1.45 min
[15:35:53] Error: Karma tests failed with exit code 1
at C:\Users\fnedelcu\Desktop\prebid\Prebid.js\gulpfile.js:278:12
at removeAllListeners (C:\Users\fnedelcu\Desktop\prebid\Prebid.js\node_modules\karma\lib\server.js:370:9)
at webServer.close (C:\Users\fnedelcu\Desktop\prebid\Prebid.js\node_modules\karma\lib\server.js:381:13)
at Server.close (net.js:1613:9)
at Object.onceWrapper (events.js:313:30)
at emitNone (events.js:111:20)
at Server.emit (events.js:208:7)
at emitCloseNT (net.js:1664:8)
at _combinedTickCallback (internal/process/next_tick.js:136:11)
at process._tickDomainCallback (internal/process/next_tick.js:219:9)
[15:35:53] 'test-coverage' errored after 1.47 min

Steps to reproduce

npm install
gulp test-coverage

Platform details

  • prebidjs - latest
  • node: 8.17.0
  • npm: 6.13.4
  • os: Windows 10 Pro version 1909
@smenzer
Copy link
Collaborator

smenzer commented May 15, 2020

@florin-nedelcu thanks for calling this out. There's a temporary fix detailed here: #5128 and I believe that #5236 intends to clean it up (along with some other improvements)

@florin-nedelcu
Copy link
Author

Thank you @smenzer! Seems like this temp fix does the job.

@stale
Copy link

stale bot commented May 30, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label May 30, 2020
@bretg bretg removed the stale label Jun 1, 2020
@bretg
Copy link
Collaborator

bretg commented Jun 1, 2020

Going to close this one out - re-open as needed.

@bretg bretg closed this as completed Jun 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants