A jest transform to facilitate testing clientside implementations within the qubit platform
- Install with
npm install --save-dev @qubit/jest jest@^26
- Add this to your package.json
"scripts": {
"test": "jest --coverage"
},
"jest": {
"transform": {
".*(.js|.css|.less)$": "@qubit/jest"
},
"transformIgnorePatterns": []
}
- Create a
placement.test.js
file You can import the setup tools withconst setup = require('@qubit/jest/setup')
- Run your test suite with
npm test
- Install with
npm install --save-dev @qubit/jest jest@^26
- Add this to your package.json
"scripts": {
"test": "jest --coverage"
},
"jest": {
"transform": {
".*(.js|.css|.less)$": "@qubit/jest"
},
"transformIgnorePatterns": []
}
- Create a
triggers.test.js
,variation-1234.test.js
file You can import the setup tools withconst setup = require('@qubit/jest/setup/experience')
- Run your test suite with
npm test
See test/placement for an example q4m test suite and test/experience for an example q4cx test suite