feat: add also language chain (#1324)

* Add `also` language chain

This would be helpful, as the property doesn't clash with other methods.

* Add `also` to tests
This commit is contained in:
sportshead 2021-02-04 19:07:26 +08:00 committed by GitHub
parent 817284c01b
commit 77565f7c2c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View file

@ -34,6 +34,7 @@ module.exports = function (chai, _) {
* - but
* - does
* - still
* - also
*
* @name language chains
* @namespace BDD
@ -43,7 +44,7 @@ module.exports = function (chai, _) {
[ 'to', 'be', 'been', 'is'
, 'and', 'has', 'have', 'with'
, 'that', 'which', 'at', 'of'
, 'same', 'but', 'does', 'still' ].forEach(function (chain) {
, 'same', 'but', 'does', 'still', "also" ].forEach(function (chain) {
Assertion.addProperty(chain);
});

View file

@ -233,7 +233,7 @@ describe('expect', function () {
[ 'to', 'be', 'been', 'is'
, 'and', 'has', 'have', 'with'
, 'that', 'which', 'at', 'of'
, 'same', 'but', 'does', 'still' ].forEach(test);
, 'same', 'but', 'does', 'still', 'also' ].forEach(test);
});
describe("fail", function() {