Mochify v5.0.0 Release Notes

  • This release REPLACES PhantomJS with Headless Chrome!

    ๐Ÿ‘€ > Not all features could be preserved, unfortunately (see known issues below). ๐ŸŽ > The improved compatibility, performance and debugging features make this a ๐Ÿš€ > great step forward, but consider this release to be potentially immature as

    the underlying Puppeteer implementation is under heavy development. โฌ†๏ธ > Carefully test whether upgrading is acceptable for your project.

    ๐Ÿ’ฅ Breaking changes

    • 0๏ธโƒฃ Runs Headless Chrome by default
    • ๐Ÿ‘ Puppeteer requires Node 6, so support for Node 4 had to be dropped.
    • ๐Ÿšš PhantomJS was removed entirely and with it the --port and --phantomjs options.
    • ๐Ÿ‘€ Downloads a recent chromium version during installation. See the install instructions in the README.md if this is causing trouble.

    ๐Ÿ†• New features

    • โœ… --url to run tests in the context of a web page can now also be used with Headless Chrome. This was previously limited to WebDriver. Can be a file: URL.
    • --https-server launches a simple HTTPS server with a self-signed certificate and tests are run in the context of an empty page. Additional files that are requested are looked up from the current directory. This can be used to run tests in a Worker. This can be combined with --url to load a specific HTML page through the HTTPS server.
    • โœ… --debug runs the tests in a full chrome instance with developer tools. Use the debugger statement to set a breakpoint.
    • --chrome allows to specify a Chrome executable to run instead of the built-in chromium.
    • ๐Ÿ’ป --no-commondir is now forwarded to Browserify

    Known issues

    • Page navigation is not prevented with Headless Chrome. Whether this is an issue depends on the way your test cases trigger page navigation.
    • โœ… Stack traces are missing in asynchronous test cases.