Skip to content

Commit

Permalink
Merge pull request #98 from danscotton/patch-1
Browse files Browse the repository at this point in the history
Update assertions.md
  • Loading branch information
jan-molak committed Sep 26, 2017
2 parents 92deea3 + 6826501 commit 014be8a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions book/design/assertions.md
Expand Up @@ -52,15 +52,15 @@ items => expect(items).to.eventually.include.('some item of interest');
could be made configurable:

```typescript
expected => actual => expect(items).to.eventually.include(expected);
expected => actual => expect(actual).to.eventually.include(expected);
```

We could also give the above function a name, and store it in our project as, say `assertions.ts`, so that
it can be reused in other scenarios:

```typescript
// assertions.ts
export include = expected => actual => expect(items).to.eventually.include(expected);
export include = expected => actual => expect(actual).to.eventually.include(expected);
```

With this one-liner in place, we could improve the task definition from the previous example:
Expand Down

0 comments on commit 014be8a

Please sign in to comment.