10 Best JavaScript Assertion Libraries

List hand-picked by Openbase Experts
Learn More

webdriverio

webdriverio

Next-gen browser and mobile automation test framework for Node.js

MIT
TypeScript Icon
TypeScript Definitions: Built-In
GitHub Stars
7.8K
Weekly Downloads
1.1M
Last Commit
9mos ago
User Rating
4.8/ 5
9
Top Feedback
3Easy to Use
2Great Documentation
2Performant
tap

tape

tap-producing test harness for node and browsers

MIT
TypeScript Icon
TypeScript Definitions: DefinitelyTyped
GitHub Stars
5.7K
Weekly Downloads
555K
Last Commit
2mos ago
User Rating
5.0/ 5
2
Top Feedback
2Easy to Use
1Great Documentation
1Performant
mocha

mocha

☕️ simple, flexible, fun javascript test framework for node.js & the browser

MIT
TypeScript Icon
TypeScript Definitions: DefinitelyTyped
GitHub Stars
21.7K
Weekly Downloads
6.8M
Last Commit
9mos ago
User Rating
4.5/ 5
137
Top Feedback
36Easy to Use
34Great Documentation
28Performant
chai

chai

BDD / TDD assertion framework for node.js and the browser that can be paired with any testing framework.

MIT
TypeScript Icon
TypeScript Definitions: DefinitelyTyped
GitHub Stars
7.7K
Weekly Downloads
5.6M
Last Commit
10mos ago
User Rating
4.8/ 5
28
Top Feedback
18Easy to Use
15Great Documentation
12Performant
ava

ava

Node.js test runner that lets you develop with confidence 🚀

MIT
TypeScript Icon
TypeScript Definitions: Built-In
GitHub Stars
20.1K
Weekly Downloads
233K
Last Commit
7mos ago
User Rating
4.5/ 5
29
Top Feedback
3Performant
2Great Documentation
2Bleeding Edge
testcafe

testcafe

A Node.js tool to automate end-to-end web testing.

MIT
TypeScript Icon
TypeScript Definitions: Built-In
GitHub Stars
9.5K
Weekly Downloads
234K
Last Commit
9mos ago
User Rating
4.2/ 5
5
Top Feedback
4Great Documentation
1Easy to Use
1Performant
assert

assert

Node.js's require('assert') for all engines

MIT
TypeScript Icon
TypeScript Definitions: DefinitelyTyped
GitHub Stars
270
Weekly Downloads
11.9M
Last Commit
3yrs ago
User Rating
5.0/ 5
1
Top Feedback
enz

enzyme

JavaScript Testing utilities for React

MIT
TypeScript Icon
TypeScript Definitions: DefinitelyTyped
GitHub Stars
Weekly Downloads
2M
Last Commit
User Rating
4.4/ 5
45
Top Feedback
12Easy to Use
10Great Documentation
2Performant
unit.js

unit.js

Simple, intuitive and flexible unit testing framework for javascript / Node.js. Integrates the great assertions libraries Must.js, Should.js, Assert of Node.js, Sinon.js and other friendly features.

Unknown
TypeScript Icon
TypeScript Definitions: Not Found
GitHub Stars
107
Weekly Downloads
25.4K
Last Commit
3yrs ago
User Rating
5.0/ 5
1
Top Feedback
tap

tap

Test Anything Protocol tools for node

ISC
TypeScript Icon
TypeScript Definitions: DefinitelyTyped
GitHub Stars
2.1K
Weekly Downloads
171K
Last Commit
8mos ago
ap

assert-plus

Extra assertions on top of node's assert module

MIT
TypeScript Icon
TypeScript Definitions: DefinitelyTyped
GitHub Stars
Weekly Downloads
20.4M
Last Commit
unexpected

unexpected

Unexpected - the extensible BDD assertion toolkit

MIT
TypeScript Icon
TypeScript Definitions: Not Found
GitHub Stars
365
Weekly Downloads
12.7K
Last Commit
7mos ago
zor

zora

Lightest, yet Fastest Javascript test runner for nodejs and browsers

MIT
TypeScript Icon
TypeScript Definitions: Built-In
GitHub Stars
476
Weekly Downloads
1.1K
Last Commit
7mos ago
power-assert

power-assert

Power Assert in JavaScript. Provides descriptive assertion messages through standard assert interface. No API is the best API.

MIT
TypeScript Icon
TypeScript Definitions: DefinitelyTyped
GitHub Stars
2.7K
Weekly Downloads
205K
Last Commit
1yr ago
ej

expect.js

BDD style assertions for node and the browser.

Unknown
TypeScript Icon
TypeScript Definitions: DefinitelyTyped
GitHub Stars
Weekly Downloads
85.4K
Last Commit
cd

chai-dom

DOM assertions for the Chai assertion library using vanilla JavaScript

MIT
TypeScript Icon
TypeScript Definitions: DefinitelyTyped
GitHub Stars
72
Weekly Downloads
53.9K
Last Commit
1yr ago
je

jasmine-expect

Write Beautiful Specs with Custom Matchers for Jest and Jasmine

MIT
TypeScript Icon
TypeScript Definitions: Built-In
GitHub Stars
572
Weekly Downloads
47.7K
Last Commit
2yrs ago
ci

chai-immutable

Chai assertions for Facebook's Immutable library for JavaScript collections

MIT
TypeScript Icon
TypeScript Definitions: Not Found
GitHub Stars
160
Weekly Downloads
17.4K
Last Commit
2yrs ago
ncc

nightwatch-custom-commands-assertions

Nightwatch.js custom commands and assertions

MIT
TypeScript Icon
TypeScript Definitions: Not Found
GitHub Stars
136
Weekly Downloads
1.4K
Last Commit
2yrs ago