🌜
🌞
karma

karma

v6.4.0

Spectacular Test Runner for JavaScript.

npm install karma

README

Karma

js-standard-style npm version npm downloads

Code Climate PRs Welcome Dependency Status devDependency Status semantic-release

A simple tool that allows you to execute JavaScript code in multiple real browsers.

The main purpose of Karma is to make your test-driven development easy, fast, and fun.

Help and Support

For questions and support please use the mailing list or Gitter. The issue tracker is for bug reports and feature discussions only.

When should I use Karma?

  • You want to test code in real browsers.
  • You want to test code in multiple browsers (desktop, mobile, tablets, etc.).
  • You want to execute your tests locally during development.
  • You want to execute your tests on a continuous integration server.
  • You want to execute your tests on every save.
  • You love your terminal.
  • You don't want your (testing) life to suck.
  • You want to use Istanbul to automagically generate coverage reports.
  • You want to use RequireJS for your source files.

But I still want to use _insert testing library_

Karma is not a testing framework, nor an assertion library. Karma just launches an HTTP server, and generates the test runner HTML file you probably already know from your favourite testing framework. So for testing purposes you can use pretty much anything you like. There are already plugins for most of the common testing frameworks:

If you can't find an adapter for your favourite framework, don't worry and write your own. It's not that hard and we are here to help.

Which Browsers can I use?

All the major browsers are supported, if you want to know more see the browsers page.

Troubleshooting

See FAQ.

I want to use it. Where do I sign?

You don't need to sign anything but here are some resources to help you to get started...

Obligatory Screencast.

Every serious project has a screencast, so here is ours. Just click here and let the show begin.

Installation.

See installation.

Using it.

See configuration.

This is so great. I want to help.

Please, see contributing.

Why did you create this?

Throughout the development of AngularJS, we've been using JSTD for testing. I really think that JSTD is a great idea. Unfortunately, we had many problems with JSTD, so we decided to write our own test runner based on the same idea. We wanted a simple tool just for executing JavaScript tests that is both stable and fast. That's why we use the awesome Socket.io library and Node.js.

My boss wants a license. So where is it?

MIT License

Release Notes

6.4.0
By Karma Bot • Published on June 14, 2022

6.4.0 (2022-06-14)

Features

  • support SRI verification of link tags (dc51a2e)
  • support SRI verification of script tags (6a54b1c)
6.3.20
By Karma Bot • Published on May 13, 2022

6.3.20 (2022-05-13)

Bug Fixes

  • prefer IPv4 addresses when resolving domains (e17698f), closes #3730
6.3.19
By Karma Bot • Published on April 19, 2022

6.3.19 (2022-04-19)

Bug Fixes

  • client: error out when opening a new tab fails (099b85e)
6.3.18
By Karma Bot • Published on April 13, 2022

6.3.18 (2022-04-13)

Bug Fixes

  • deps: upgrade socket.io to v4.4.1 (52a30bb)
6.3.17
By Karma Bot • Published on February 28, 2022

6.3.17 (2022-02-28)

Bug Fixes

  • deps: update colors to maintained version (#3763) (fca1884)
6.3.16
By Karma Bot • Published on February 10, 2022

6.3.16 (2022-02-10)

Bug Fixes

  • security: mitigate the "Open Redirect Vulnerability" (ff7edbb)
6.3.15
By Karma Bot • Published on February 5, 2022

6.3.15 (2022-02-05)

Bug Fixes

6.3.14
By Karma Bot • Published on February 5, 2022

6.3.14 (2022-02-05)

Bug Fixes

  • remove string template from client code (91d5acd)
  • warn when singleRun and autoWatch are false (69cfc76)
  • security: remove XSS vulnerability in returnUrl query param (839578c)
6.3.13
By Karma Bot • Published on January 31, 2022

6.3.13 (2022-01-31)

Bug Fixes

  • deps: bump log4js to resolve security issue (5bf2df3), closes #3751
6.3.12
By Karma Bot • Published on January 24, 2022

6.3.12 (2022-01-24)

Bug Fixes

  • remove depreciation warning from log4js (41bed33)

General

License
MIT
Typescript Types
Tree-shakeable
No

Popularity

GitHub Stargazers
11.8K
Community Interest
14.1K
Number of Forks
1,750

Maintenance

Commits
10/219/22015
Last Commit
Open Issues
322
Closed Issues
1,698
Open Pull Requests
15
Closed Pull Requests
880

Versions

Versions Released
10/219/2204
Latest Version Released
Jun 14, 2022
Current Tags
latest6.4.0

Contributors

vojtajina
vojtajina
Commits: 934
dignifiedquire
dignifiedquire
Commits: 296
johnjbarton
johnjbarton
Commits: 149
devoto13
devoto13
Commits: 98
greenkeeperio-bot
greenkeeperio-bot
Commits: 67
lusarz
lusarz
Commits: 52
semantic-release-bot
semantic-release-bot
Commits: 35
karmarunnerbot
karmarunnerbot
Commits: 35
budde377
budde377
Commits: 26
wesleycho
wesleycho
Commits: 14
taichi
taichi
Commits: 14
maksimr
maksimr
Commits: 12
mgol
mgol
Commits: 11
twolfson
twolfson
Commits: 11
anthony-redFox
anthony-redFox
Commits: 11