Skip to content

Latest commit

 

History

History
66 lines (55 loc) · 3.27 KB

File metadata and controls

66 lines (55 loc) · 3.27 KB

0.18.0

Released 11/27/2016

Notes:

  • We've created a new example recipes repo to show you common testing scenarios including how to use the new module support.

Summary:

  • We've added automatic ES2015+, module, JSX, and CJSX support to all test files. This means you can use require, import, or export declarations to load other files. You can also use this to import your own application specific JavaScript modules and write unit tests for them. More of these details are yet to come. See this issue.
  • You can now use your regularly installed node_modules in your project to do things like utilizing lodash for utility functions or extending chai with assertion plugins.
  • Because we're now processing the spec files prior to handing them off to the browser, this means we will display problems like syntax errors when something in the processing goes wrong. Additionally, we print these out during cypress run, so you're not stuck wondering what went wrong.

Breaking Changes:

  • Previously, we auto-magically included all files within cypress/support. This has now gone away and we've simplified this to automatically including a single cypress/support/index.js file. That single file acts as the entry point meaning you should import or require the other support files you'd like to include. Although this is still "automatic" it's much less magical and we'll be updating all of our docs to reflect this. The purpose of cypress/support hasn't really changed, just the implementation of it has. We will automatically seed a cypress/support/index.js file for you (even on existing projects). The file location of cypress/support/index.js can be changed with the new supportFile option in your cypress.json. This feature can also be turned off by specifying supportFile: false.

Features:

  • We now support ES2015+, modules, and JSX in all spec files. Fixes #246.
  • Spec files may now be written as .js, .jsx, .coffee, or cjsx files.
  • Test files with JS syntax errors are now handled and we provide a GUI that points to the exact line/column number. Additionally we print these out during cypress run and exit the process with code 1. Fixes #293.

Misc:

  • We improved the logic around when and if we scaffold files on a new project. We're much smarter about this and not generating these forcibly every time. Fixes #285.
  • Simplified handling of support files and made them less "magical". Fixes #286.
  • Renamed supportFolder to supportFile in cypress.json. We will automatically rename your cypress.json if this property was present on update.