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

Html Reporter throws stacktrace immediately on execution #114

Closed
AutomatedTester opened this issue Dec 4, 2011 · 6 comments
Closed

Html Reporter throws stacktrace immediately on execution #114

AutomatedTester opened this issue Dec 4, 2011 · 6 comments

Comments

@AutomatedTester
Copy link

AutomatedTester commented Dec 4, 2011

Edit (@JoshuaKGoldberg, January 2024): see #114 (comment) below.


When I try mocha tests/* --globals name --reporter html i get

node.js:201
        throw e; // process.nextTick error, or 'error' event on first tick
              ^
ReferenceError: $ is not defined
    at new HTML (/usr/local/lib/node_modules/mocha/lib/reporters/html.js:40:14)
    at run (/usr/local/lib/node_modules/mocha/bin/mocha:176:18)
    at /usr/local/lib/node_modules/mocha/bin/mocha:168:16
    at Array.forEach (native)
    at Object.<anonymous> (/usr/local/lib/node_modules/mocha/bin/mocha:163:7)
    at Module._compile (module.js:432:26)
    at Object..js (module.js:450:10)
    at Module.load (module.js:351:31)
    at Function._load (module.js:310:12)
    at Array.0 (module.js:470:10)
    at EventEmitter._tickCallback (node.js:192:40)```
@AutomatedTester
Copy link
Author

I was just trying this to see what the reporter looked like.

@AutomatedTester
Copy link
Author

Should have said this is with 0.2.0 and on OSX 10.6

@tj
Copy link
Contributor

tj commented Dec 4, 2011

html is the client-side one, maybe you were looking for the doc reporter

@tj
Copy link
Contributor

tj commented Dec 4, 2011

maybe html should be dom and doc should be html

@tj
Copy link
Contributor

tj commented Jun 17, 2012

This issue has been inactive for over 1 month so I'm closing it. If you think it's still an issue re-open. - tjbot

@tj tj closed this as completed Jun 17, 2012
@JoshuaKGoldberg
Copy link
Member

Fun fact: this issue is linked on StackOverflow! https://stackoverflow.com/questions/19974122/using-html-reporting-with-mocha-test-framework

https://mochajs.org/#running-mocha-in-the-browser has docs for running Mocha in the browser right now. I added a standalone example to the mocha-examples repository here mochajs/mocha-examples#72.

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