expectations

jasmine-style 'expect' calls for mocha and other test frameworks

0BSD 16 个版本
安装
npm install expectations
yarn add expectations
pnpm add expectations
bun add expectations
README

Build Status

Jasmine-style expectations for node.js & the browser

This is a standalone package that supplies jasmine style expect(foo).toEqual(bar);-style expectations.

Designed for use in mocha, but suitable for use in any test framework.

Installation

  • NodeJS: npm install expectations
  • Browser: Download manually, or bower install expectations

Usage

NodeJS:

require('expectations');	// exports a global, so use anywhere

From Mocha (on commandline or add to test/mocha.opts):

--require expectations

In browser:

<script src="expectations.js"></script>

API

We aim to support the majority of the jasmine expect API, but there are likely things missing. Pull Requests (with tests!) graciously accepted.

版本列表
1.0.0 2019-02-23
0.7.1 2017-01-26
0.7.0 2017-01-18
0.6.0 2016-05-03
0.5.2 2015-10-04
0.5.1 2015-05-14
0.5.0 2015-05-14
0.4.2 2015-03-10
0.4.1 2015-02-23
0.4.0 2015-02-21
0.3.1 2015-02-17
0.3.0 2014-11-30
0.2.5 2013-10-15
0.2.2 2013-10-02
0.2.0 2013-06-06
0.1.6 2012-06-30