Security News
Cloudflare Adds Security.txt Setup Wizard
Cloudflare has launched a setup wizard allowing users to easily create and manage a security.txt file for vulnerability disclosure on their websites.
carma-tap-webpack
Advanced tools
add Karma, TAP and webpack boilerplate test settings to projects
Setting Karma
with many plugins it´s a time consuming process, many hours of trial and error. Now you have it all for free.
npm 3
environments and beyond. Don´t use it with npm 2
karma-chrome-launcher
, karma-jsdom-launcher
, ...webpack
is needed for test?browserify
but we opinionated on webpack
autowatch
mode for a good performance a robust cache and rebuild solution is needed, webpack
is best on this apart.karma
complex setup, why not just use the very simple tape?If your project tests need
Karma will provide it!
npm install karma webpack carma-tap-webpack --save-dev
karma.conf.js
to project folderconst carma = require('carma-tap-webpack');
module.exports = function(config) {
carma(config);
}
Custom karma settings can be added or defaults can be override. Defaults settings karma.conf.js
package.json
"scripts": {
"karma": "karma start",
"testonly": "npm run karma",
"test": "npm run testonly"
},
By default Karma will search for files on project root test
folder but this can be customize.
Example of project´s karma.conf.js
const carma = require('carma-tap-webpack');
const webpack = require('webpack');
module.exports = function(config) {
carma(config);
config.set({ // overriding inherited settings
// Set browser launcher
browsers: process.env.CONTINUOUS_INTEGRATION === 'true' ? ['Firefox'] : ['jsdom'],
webpack: {
plugins: [
// __TEST_DIR__ path '../../' is relative to inherited 'basePath' from 'carma'
// __TEST_REGX__ file pattern match
new webpack.DefinePlugin({
'__TEST_DIR__': JSON.stringify('../../' + 'spec'),
'__TEST_REGX__': /^.+\.(js|jsx)+$/g
})
]
}
});
}
carma-tap-webpack
1.0.5
FAQs
add Karma, Tap and Webpack boilerplate setup files
The npm package carma-tap-webpack receives a total of 7 weekly downloads. As such, carma-tap-webpack popularity was classified as not popular.
We found that carma-tap-webpack demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Cloudflare has launched a setup wizard allowing users to easily create and manage a security.txt file for vulnerability disclosure on their websites.
Security News
The Socket Research team breaks down a malicious npm package targeting the legitimate DOMPurify library. It uses obfuscated code to hide that it is exfiltrating browser and crypto wallet data.
Security News
ENISA’s 2024 report highlights the EU’s top cybersecurity threats, including rising DDoS attacks, ransomware, supply chain vulnerabilities, and weaponized AI.