diff options
| author | Romaric Pascal <[email protected]> | 2022-12-24 23:29:20 +0100 |
|---|---|---|
| committer | GitHub <[email protected]> | 2022-12-24 14:29:20 -0800 |
| commit | 33ccbc23e383d9b5a9c53379791892cc73d72f21 (patch) | |
| tree | 9b2b845bb619318bea76270c829e606c963d3295 /package.json | |
| parent | cf9454caa00872899215603e5e036d9a824b1b11 (diff) | |
| download | bootstrap-33ccbc23e383d9b5a9c53379791892cc73d72f21.tar.xz bootstrap-33ccbc23e383d9b5a9c53379791892cc73d72f21.zip | |
SCSS testing of the utilities API (#36029)
* Set up CSS testing using sass-true and mocha
Use mocha to handle the heavy lifting of finding tests and running them.
Mocha is made to look directly for SCSS files which are compiled
thanks to Node's require.extensions mechanism.
* Add CSS tests to workflow
* Add tests for the generate-utility mixin
* Add tests for utilities generation
* Fix linting issues
* Fix test contents
Don't know why the whole utilities.test.scss ended up copied in the api.test.scss
* Remove unnecessary entry in package.json
* Move to Jasmine for running the tests
* Move running of CSS tests before CSS build
* Update linting set up
Add exceptions for test files in stylelint
* Remove irrelevant option for sass-true
* Fix linting issues after rebase
* Add color mode tests
* Fix linter
Co-authored-by: Mark Otto <[email protected]>
Diffstat (limited to 'package.json')
| -rw-r--r-- | package.json | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/package.json b/package.json index b9aaebb57..325454e3c 100644 --- a/package.json +++ b/package.json @@ -54,6 +54,7 @@ "css-prefix-main": "postcss --config build/postcss.config.js --replace \"dist/css/*.css\" \"!dist/css/*.rtl*.css\" \"!dist/css/*.min.css\"", "css-prefix-examples": "postcss --config build/postcss.config.js --replace \"site/content/**/*.css\"", "css-prefix-examples-rtl": "cross-env-shell NODE_ENV=RTL postcss --config build/postcss.config.js --dir \"site/content/docs/$npm_package_config_version_short/examples/\" --ext \".rtl.css\" --base \"site/content/docs/$npm_package_config_version_short/examples/\" \"site/content/docs/$npm_package_config_version_short/examples/{blog,carousel,dashboard,cheatsheet}/*.css\" \"!site/content/docs/$npm_package_config_version_short/examples/{blog,carousel,dashboard,cheatsheet}/*.rtl.css\"", + "css-test": "jasmine --config=scss/tests/jasmine.js", "js": "npm-run-all js-compile js-minify", "js-compile": "npm-run-all --aggregate-output --parallel js-compile-*", "js-compile-standalone": "rollup --environment BUNDLE:false --config build/rollup.config.js --sourcemap", @@ -94,6 +95,7 @@ "watch-css-main": "nodemon --watch scss/ --ext scss --exec \"npm-run-all css-lint css-compile css-prefix\"", "watch-css-dist": "nodemon --watch dist/css/ --ext css --ignore \"dist/css/*.rtl.*\" --exec \"npm run css-rtl\"", "watch-css-docs": "nodemon --watch site/assets/scss/ --ext scss --exec \"npm run css-lint\"", + "watch-css-test": "nodemon --watch scss/ --ext scss,js --exec \"npm run css-test\"", "watch-js-main": "nodemon --watch js/src/ --ext js --exec \"npm-run-all js-lint js-compile\"", "watch-js-docs": "nodemon --watch site/assets/js/ --ext js --exec \"npm run js-lint\"" }, @@ -124,6 +126,7 @@ "hammer-simulator": "0.0.1", "hugo-bin": "^0.96.0", "ip": "^2.0.0", + "jasmine": "^4.0.2", "jquery": "^3.6.2", "karma": "^6.4.1", "karma-browserstack-launcher": "1.4.0", @@ -143,6 +146,7 @@ "rollup-plugin-istanbul": "^4.0.0", "rtlcss": "^4.0.0", "sass": "^1.57.1", + "sass-true": "^6.1.0", "shelljs": "^0.8.5", "stylelint": "^14.16.0", "stylelint-config-twbs-bootstrap": "^7.0.0", |
