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

Broken after upgrading to 2.0. #109

Closed
pinalbhatt opened this issue Jan 5, 2017 · 10 comments
Closed

Broken after upgrading to 2.0. #109

pinalbhatt opened this issue Jan 5, 2017 · 10 comments

Comments

@pinalbhatt
Copy link

Everything was running fine for me on 1.5.4.
After upgrading to 2.0

  1. MOCHAWESOME_REPORTNAME = 'index' is not working. it generates report with default name only.

  2. MOCHAWESOME_AUTOOPEN = true is also not working.

  3. When report (html file) opened it shows part of source code only and not any report.

@SureshRajpurohit85
Copy link

SureshRajpurohit85 commented Jan 9, 2017

WRT to the report HTML file even i am facing the same issue after upgrading to 2.0

the source code starts with something like this :

",returnEnd:!0,subLanguage:["actionscript","javascript","handlebars","xml"]}},{className:"meta",variants:[{begin:/<?xml/,end:/?>/,relevance:10},{begin:/<?\w+/,end:/?>/}]},{className:"tag",begin:"", ......

but the JSON file is created appropriatly

@adamgruber
Copy link
Owner

@pinalbhatt It's mentioned in the docs that the option MOCHAWESOME_REPORTNAME was renamed to MOCHAWESOME_REPORTFILENAME in v2. As for MOCHAWESOME_AUTOOPEN, I'll have to look into it further.

It's much easier if you can provide some example code.

@bonesoul
Copy link

I'm having the exact same error with report file.

@adamgruber
Copy link
Owner

adamgruber commented Jan 12, 2017

Update

For some reason when splitting out the report generation code for v2, the autoOpen functionality was dropped. Added it back here: adamgruber/mochawesome-report-generator#1

The issue with the inlineAssets option was a misconfiguration with webpack UglifyJS plugin. It wasn't escaping <script> tags properly. Fixed the setting here: adamgruber/mochawesome-report-generator#2

Look for an updated release with these changes in the next day or so. Maybe sooner.

@adamgruber
Copy link
Owner

2.0.1 is released

@bonesoul
Copy link

I've tried 2.0.1 but it still didn't fix.

@adamgruber
Copy link
Owner

@bonesoul Did you do an npm install after upgrading? Need to make sure you are running mochawesome-report-generator@1.0.3

@pinalbhatt
Copy link
Author

pinalbhatt commented Jan 16, 2017

@adamgruber 2.0.1 works for me, but it is still missing some features from 1.5.5

  1. Date/Time stamp missing in main page. (its in side drawer but still i would prefer on main page just like in 1.5.5)

  2. in 2.0.1 In top bar showing time to run test, # of suites, # of tests, #of passing tests, # of failing tests. here # of pending tests is missing.

  3. in 2.0.1 In top bar showing time to run test, # of suites, # of tests, #of passing tests, # of failing tests - these items are not clickable so filtering does not work.

  4. Also expand/collapse at test level is missing.

  5. Also addContext does not work when ES6 arrow function notation used as 'this' is not valid context in such case.

@adamgruber
Copy link
Owner

@pinalbhatt

  1. It was a design decision to move the timestamp into the drawer.
  2. The report will show # of pending tests if they exist but it is hidden when there are no tests pending. Again, design decision to save space.
  3. Filtering controls were moved into the drawer
  4. Not seeing any issues with collapsing/expanding tests. Can you be more specific or provide an example?
  5. This is mentioned in the docs and is just a side effect of using arrow functions. In order to add context to the test object you need a reference to it.

@pinalbhatt
Copy link
Author

Thanks @adamgruber for above information.

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

4 participants