Released 06/11/2016
Features:
- Added new
cy.screenshot()
command which can take screenshots on demand. - When running
cypress run
or in CI, Cypress will now automatically take a screenshot when a test fails. You can optionally turn this off by settingscreenshotOnHeadlessFailure
tofalse
in your configuration. - Added new
screenshotsFolder
configuration option with default ofcypress/screenshots
. - When running in Circle CI, we automatically export
screenshots as artifacts which makes them available directly in their web UI.
If you're using Circle CI, you'll be able to see screenshots without doing
anything. If you're using Travis CI, you'll need to
upload artifacts to an
s3 bucket
. This is a small slice of what is coming to help diagnose and understand errors in CI. Also in0.17.0
we will automatically scroll the tests and more intelligently and open / close test commands so you can visually see what happened. Currently you may not see the test command's failure in the Command Log due to the view not scrolling. - Added new
.each()
command which iterates serially on a collection yielding the iteratee, the index, and the collection. Addresses #156. cy.route()
can now accept a single function and/or you can pass a function to theresponse
property. This allows you to lazily evaluate routing responses. Great for referencing fixtures. Addresses #152.cy.contains()
now accepts a regular expression. Addresses #158..type()
now accepts{downarrow}
and{uparrow}
. We do not move the caret but do fire all the proper events. Addresses #157.
Bugfixes:
cy.exec()
now outputs additionalstderr
andstdout
information. It additionally will automaticallysource
your$SHELL
which makes GUI apps behave as if they've been launched from your terminal. Fixes #153 and #154..then()
yielding nested subjects.cy.contains()
no longer returns the last element found when siblings both contain the same content. Fixes #158.- Cypress no longer errors when you return a raw DOM element. It now correctly wraps this as the new subject.
Misc:
cy.contains()
now provides an even more specific error message when it was scoped to a particular DOM element and contained a selector. Fixes #160.- You will now see a very specific error message when we detect that you've
mixed up
async
andsync
code in a.then()
callback function. An example would be queuing up a new cypress command but then synchronously returning a different value.