testcafe: Script that worked in version 1.5.0 but no longer works in 1.9.4.

What is the current behavior?

I have a script that worked in version 1.5.0 but no longer works in 1.9.4. When I run the coffee test script, the following error occurs:

 e[t].log is undefined

In debugging it turns out this line corresponds to a simple console.log(…)

Capture01

Steps to reproduce:

  1. Download test-simple-example.js.txt (remove extension .txt)
  2. Download basic-page-model.js.txt (remove extension .txt)
  3. run testcafe firefox test-simple-example.js

Environment details:

  • testcafe version: 1.9.4
  • node.js version: 10.16.3
  • browser name and version: firefox 81.0 but same problem on chrome 85.0.4183.121
  • platform and version: Windows 10 Pro

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Comments: 15 (8 by maintainers)

Commits related to this issue

Most upvoted comments

@frejfrej, We can’t share a time frame as any personal estimations may be misleading. However, considering the activity in this thread, we’ve raised the priority for this issue. We will consider fixing it in one of our next sprints.

@Sabou44, Thank you for the confirmation email. I’ve reproduced this issue. I got a slightly different error message than the one you shared, but it’s clear that both of them refer to the same object. We need more time to investigate the issue. Once it’s fixed, we’ll update this thread.

For the team:

The error message:

1) A JavaScript error occurred on "https://wc-111-giessen.sodius.cloud/Windchill/app/#ptc1/tcomp/infoPage?ContainerOid=OR%3Awt.pdmlink.PDMLinkProduct%3A127278&oid=VR%3Awt.part.WTPart%3A127515&u8=1".
      Repeat test actions in the browser and check the console for errors.
      If you see this error, it means that the tested website caused it. You can fix it or disable tracking JavaScript errors in TestCafe. To do the latter, enable the "--skip-js-errors" option.
      If this error does not occur, please write a new issue at:
      "https://github.com/DevExpress/testcafe/issues/new?template=bug-report.md".

      JavaScript error details:
      TypeError: Cannot read property 'slice' of undefined
          at http://172.27.63.129:62528/testcafe-driver.js:1:9880
          at Array.forEach (<anonymous>)
          at Yn.getCopy (http://172.27.63.129:62528/testcafe-driver.js:1:9841)
          at ra.set (http://172.27.63.129:62528/testcafe-driver.js:1:54095)
          at ra._onConsoleMessage (http://172.27.63.129:62528/testcafe-driver.js:1:56707)
          at t.<anonymous> (http://172.27.63.129:62528/testcafe-driver.js:1:83391)
          at t.emit (http://172.27.63.129:62528/hammerhead.js:15:5984)
          at console.window.console.<computed> [as log] (http://172.27.63.129:62528/hammerhead.js:6:17322)
          at Object.Sodius.windchill.loader.onReady (https://wc-111-giessen.sodius.cloud/Windchill/netmarkets/javascript/util/windchill-all.js:3100:52)
          at EXTUTIL.Event.fire (https://wc-111-giessen.sodius.cloud/Windchill/netmarkets/javascript/util/ext-and-extensions.js:59:325)

      Browser: Chrome 85.0.4183.121 / Windows 10

          9 |
         10 |const page = new Page();
         11 |
         12 |const selectProvider= async(t)=>{
         13 |    await t
       > 14 |           .click(page.spanCollaborationLink)
         15 |           .click(page.plusLinkButton)
         16 |           .click(page.combo_linkkinds)
         17 |           .click(page.combo_linkkindsOption.withText(linktype))
         18 |           .click(page.combo_providers)
         19 |           .click(page.combo_providersOption.withText('CLI-E2E-PROJECT'))

         at <anonymous> (D:\Work\tests\log-test\test-simple-example.js:14:4)
         at selectProvider (D:\Work\tests\log-test\test-simple-example.js:12:7)
         at <anonymous> (D:\Work\tests\log-test\test-simple-example.js:26:8)
         at <anonymous> (D:\Work\tests\log-test\test-simple-example.js:24:1)

image

TestCafe v1.9.4