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

Problem with mochawesome: TypeError: Cannot read properties of undefined (reading 'length') #66

Closed
quad5 opened this issue Mar 17, 2022 · 3 comments
Labels
bug Something isn't working

Comments

@quad5
Copy link

quad5 commented Mar 17, 2022

Environment

Versions that don't work.
- OS: Mac 11.6
- Node:  16.5.0
- cypress-mochawesome-reporter: 3.0.0
- cypress: 9.7.2
- mochawesome: 7.1.2

Versions that works
- OS: Mac 11.6
- Node: 16.14.0
- cypress-mochawesome-reporter: 2.3.0
- cypress: 9.7.2
- mochawesome: 6.3.1

What happened?

Please see the issue I logged with mochawesome. I am not sure who is the culprit.

Config file

The config file below is the working versions one. See Environment section for non-working versions.

{
  "name": "automation-testing",
  "version": "1.0.0",
  "description": "Automation Testing using js",
  "main": "index.js",
  "scripts": {
    "test": "cypress"
  },
  "author": "",
  "license": "ISC",
  "devDependencies": {
    "@babel/plugin-proposal-private-methods": "^7.12.1",
    "cypress": "9.5.2",
    "cypress-fail-fast": "3.4.1"
  },
  "dependencies": {
    "@babel/core": "7.11.6",
    "chai": "4.2.0",
    "chai-string": "^1.5.0",
    "cypress-file-upload": "5.0.5",
    "cypress-localstorage-commands": "1.7.0",
    "cypress-mochawesome-reporter": "2.3.0",
    "cypress-terminal-report": "^2.2.0",
    "deepmerge": "^4.2.2",
    "lodash": "^4.17.21",
    "lodash.clonedeep": "4.5.0",
    "mocha": "9.2.2",
    "mochawesome": "6.3.1",
    "path": "^0.12.7",
    "uuid": "^8.3.0"
  }
}

Relevant log output

No response

Anything else?

No response

@quad5 quad5 added the bug Something isn't working label Mar 17, 2022
@Idleness76
Copy link

@LironEr I also commented on the bug linked above. This seems to occur if there are spec files that are either skipped, or otherwise don't have any tests present.

@LironEr
Copy link
Owner

LironEr commented Apr 12, 2022

Hey, sorry for the late response.

Is the issue still happening after upgrading mochawesome? adamgruber/mochawesome#373

I will release a new version (3.0.1) with the updated mochawesome in the next hour

@Idleness76
Copy link

@LironEr this was fixed with moachawesome 7.1.3 and should be fine to include the latest version.

@LironEr LironEr closed this as completed Apr 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants