mirror of
https://github.com/flarum/framework.git
synced 2025-02-27 15:53:11 +08:00

* feat(jest): create jest config package for unit testing * chore: housekeeping * fix: now we need to explicitly allow importing without extension * fix: recover EditorDriverInterface import * Apply suggestions from code review * chore: yarn Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
540 B
Executable File
540 B
Executable File
Jest config for Flarum
This package provides a Jest config object to run unit & integration tests on Flarum extensions.
Usage
- Install the package:
yarn add --dev flarum-jest-config
- Add
"type": "module"
to yourpackage.json
- Add
"test": "yarn node --experimental-vm-modules $(yarn bin jest)"
to yourpackage.json
scripts - Rename
webpack.config.js
towebpack.config.cjs
- Create a
jest.config.cjs
file with the following content:
module.exports = require('flarum-jest-config')();