1.1.0 ā€¢ Published 2 years ago

estuaire v1.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

estuaire

āš” super fast javascript testing tool āš”


šŸ“¦ repository šŸ“œ documents

Features

  • āš” lightning fast
  • šŸŽØ extensible expect
  • šŸ¦„ typescript supported
  • šŸ› ļø not required config

Usage

yarn add -D estuaire
"scripts": {
+  "test": "estuaire"
}
// test/index.test.ts
import { expect, describe } from 'estuaire';

describe('sum', () => {
  expect(1 + 2).toBe(3);
});

Matcher

const nullValue = null;
const undefinedValue = undefined;
const array = ['ping', 'pong'];
const string = 'hello world';
const number = 2 + 2;

// matchers
expect('hello').toBe('hello');
expect({ a: 10 }).toEqual({ a: 10 });

// truthiness

expect(nullValue).not.toBeDefined();
expect(nullValue).toBeNull();
expect(nullValue).not.toBeUndefined();

expect(undefinedValue).not.toBeDefined();
expect(undefinedValue).toBeUndefined();

// string

expect(string).toContain('hello');
expect(string).toIncludes('hello');

// array

expect(array).toIncludes('ping');
expect(array).toContain('ping');

// number

expect(number).toBeGreaterThan(3);
expect(number).toBeGreaterThanOrEqual(4);
expect(number).toBeLessThan(5);
expect(number).toBeLessThanOrEqual(4);

License

MIT

1.1.0

2 years ago

1.0.0

2 years ago

0.3.1

2 years ago

0.3.0

2 years ago

0.1.0

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago

0.0.0

2 years ago