* Basic macro support.
This adds basic macro support as discussed in #695.
It does not completely implement the spec outlined there, specifically:
- The macro can only specify the title using a function in `macroFn.title`. We discussed allowing `macroFn.title` to also be a string, and allowing some form of template language for extracting a title. However, using ES2015 string templates is already pretty easy, so we may just skip this.
- We discussed allowing groups of tests to be created using arrays.
Both the above proposals are found in [this comment](https://github.com/sindresorhus/ava/issues/695#issuecomment-205929738). They both enhance the implementation found in this commit, and would not break the contract. So I don't think there is anything preventing us from shipping this now.
* fix readme indentation
* spread arguments
* Allow arrays of macros
* pass providedTitle as first argument to title function.
* improve docs
* change failing test hint
* mark .failing as code in readme
* group and reword failing tests
The tests are better when grouped together. I tried to give them more consistent titles too.
* remove spurious trailing space in t.end error message
Fixes#474
* add after.always, afterEach.always hook
* update readme about always modifier
* add test for verifying throw
* add tests for verifying always hook are added
* update readme for better "always" explaination
* fix typo in test/test-collection.js
* better always checking and implement
* modify error message for only
* fix build error
* add always to default in test
* detect improper use of t.throws
Protects against a common misuse of t.throws (Like that seen in #739).
This required the creation of a custom babel plugin.
https://github.com/jamestalmage/babel-plugin-ava-throws-helper
* relative file path and colors
* protect against null/undefined in _setAssertError
* use babel-code-frame to do syntax highlighting on the Error
* require `babel-code-frame` inline. It has a sizable dependency graph
* remove middle section of message. It is redundant given code-frame
* further tests and add documentation.
* update readme.md
* refactor `ok` to `truthy` and `notOk` to `falsy`
* update tests to be more explicit
* update docs to use a better assertion api
* realign power-assert output
* quick typo fix
* update assertions
npmjs.com does not correctly display the gitter badge. My guess is that it's due to the unencoded space character in the image URL (won't know for sure until we publish again).