Package Exports
- poku
- poku/lib/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (poku) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Poku
Poku can show you how simple testing can be ๐ฑ
Enjoying Poku? Give him a star to show your support โญ๏ธ
Why does Poku exist?
Poku takes on the testers' difficulties by itself and lets you focus on the tests.
No configurations
Auto detect ESM and CJS
Auto detect Typescript files
Run the same test suite for Node.js, Bun and Deno
Easier and Less Verbose
Node.js familiar API
Easily test your server just by running it ๐
Run CJS (CommonJS) files directly with Deno
Easily handle services, servers, processes and ports
Safety and Reliability
High isolation level per file
Performant and lightweight
Compatible with Coverage tools
Poku doesn't use
eval nor global state ๐
In other words, you can run your tests directly, without relying on Poku
Quickstart
Install
Node.js |
TypeScript + Node.js |
Bun |
Deno |
npm i -D poku |
npm i -D poku tsx |
bun add -d poku |
deno add npm:poku |
Test
test/file.test.mjs |
import { assert } from 'poku';
assert(true, 'Poku will describe it ๐ท'); |
Run
Node.js (and TypeScript) |
Bun |
Deno |
npx poku |
bunx poku |
deno run npm:poku |
That's it ๐
๐ท Documentation โข ๐งช Examples โข ๐ฌ Compare the Most Popular Test Runners
Available Methods
Essentials
- Test
- Background Services
- startScript (run
package.jsonscripts in a background process) - startService (run files in a background process)
- startScript (run
Helpers
- test
- describe and it
- beforeEach and afterEach
- Processes
- and much more โจ
Documentation and Examples
To see the detailed documentation, please visit the Documentation and Examples sections in the Poku's website.
Contributing
I'm continuously working to improve Poku. If you've got something interesting to share, feel free to submit a Pull Request. If you notice something wrong, I'd appreciate if you'd open an Issue.
Please check the CONTRIBUTING.md for instructions ๐
Philosophy
Please check the Philosophy section from Documentation.
Security Policy
Please check the SECURITY.md and the section Is Poku Safe? from Documentation.
Quick Comparisons
Performance
Poku is continuously tested (CI) to ensure the following expectations:
- ~4x faster than Jest (v29.7.0)
- ~3x faster than Vitest (v1.6.0)
- ~1x faster than Mocha (v10.4.0) + Chai (v5.1.1)
You can see how the tests are run and compared in the benchmark directory.
Installation Size
Limitations
- Poku community is gradually building up ๐ค
- Although it has no external dependencies, Poku is not all-in-one, so it doesn't have features such as mocks and spies, where you can use your favorite packages or native solutions.
Acknowledgements
License
Poku is under the MIT License.