Mocaccino.js
Mocha test runner as a Browserify plugin
Install / Use
/learn @mantoni/Mocaccino.jsREADME
mocaccino
Mocha test runner as a Browserify plugin.
Install
npm install mocaccino --save-dev
Real browser testing
This module is developed as part of Mochify which allows you to run tests with a headless browser, on a Selenium grid, in the cloud with SauceLabs or generates a standalone HTML page to run the tests. The underlying modules can also be used as Browserify plugins.
- min-webdriver for Selenium and SauceLabs support
- Consolify to generate a standalone HTML page
Code coverage with node
Use the Coverify transform and node:
$ browserify --bare -p [ mocaccino --node ] -t coverify test.js | node | coverify
Usage
Mocaccino is a browserify plugin:
browserify -p [ mocaccino OPTIONS ]
where OPTIONS are:
--reporter, -R Mocha reporter to use, defaults to "tap"
--grep Mocha grep option
--fgrep Mocha fgrep option
--invert Mocha invert option
--timeout, -t Mocha timeout in milliseconds to use, defaults to 2000
--ui, -U Mocha user interface to use, defaults to "bdd"
--yields, -y Yield every N milliseconds, defaults to 250
--node If result is used in node instead of a browser
--windowWidth Overrides the window width, defaults to the current shells
window width or fall back to 80
--no-colors Disable colors (overrides color support detection)
--colors Enable colors (overrides color support detection)
--mochaPath Path to custom Mocha module
The yields option causes a tiny delay every N milliseconds to allow pending
I/O to happen. It's ignored if --node is given.
Compatibility
- Node 12 or later
- Browserify 5.9 or later (since version 1.0.0)
- Browserify 4.x (before 1.0.0)
License
MIT
Related Skills
gh-issues
340.5kFetch GitHub issues, spawn sub-agents to implement fixes and open PRs, then monitor and address PR review comments. Usage: /gh-issues [owner/repo] [--label bug] [--limit 5] [--milestone v1.0] [--assignee @me] [--fork user/repo] [--watch] [--interval 5] [--reviews-only] [--cron] [--dry-run] [--model glm-5] [--notify-channel -1002381931352]
node-connect
340.5kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
84.2kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
Writing Hookify Rules
84.2kThis skill should be used when the user asks to "create a hookify rule", "write a hook rule", "configure hookify", "add a hookify rule", or needs guidance on hookify rule syntax and patterns.
