karma-runner / karma-runner/karma
Potential v7 breaking changes
- Dominant language
- JavaScript
- Stars
- 12k
- Forks
- 1.7k
- PR merge metrics
- No merged PRs in 30d
Description
This issue is to track potential improvements to Karma, which require breaking changes. It will be updated with more points as I discover them.
- [ ] Drop support for IE < 11 and other obsolete browsers to simplify Karma code and allow using more modern JS in the client code. I think it is reasonable to support same set as [Angular does](https://angular.io/guide/browser-support#browser-support), but open for suggestions.
- [ ] Use the `Array.prototype.includes()` method instead of a full-fledged for-loop in https://github.com/karma-runner/karma/blob/6b3bf3b295febc4a6b47bb284bbcae68d648ec72/client/karma.js#L242
- [ ] Update mocha - it is currently used for cross-browser testing and hence blocked
- [ ] Switch from `socket.io` to `ws` to simplify code and reduce amount of dependencies (WebSockets [are supported](https://caniuse.com/#feat=websockets) in any reasonably alive browsers, so it may be a good point for a switch as we no longer need fallback mechanisms with only IE 11 supported) - **may not do that given that not all proxies, e.g. BrowserStack Local support WebSockets**
- [ ] Remove buffering logic for test results (#3684)
- [ ] Remove deprecated `customFileHandlers` provider once ecosystem is ready
- [ ] Remove support for `http2` module. It was implemented over a long deprecated https://yarnpkg.com/package/http2 package. WebSockets in general (https://github.com/websockets/ws/issues/1458) and socket.io, in particular, do not work over HTTP/2 (https://github.com/socketio/socket.io/issues/3564). Node's `http2` module is not compatible with `http` and `https`, so we'll have to build some complex adapters. And on top of that, the current implementation does not seem to work at the moment (https://github.com/karma-runner/karma/issues/2761).
- [ ] Drop Node 10 support as it is reaching EOL (https://nodejs.org/en/about/releases/) and blocks dependency updates (https://github.com/karma-runner/karma/pull/3686)
- [ ] Update "@commitlint/config-angular" as mentioned in https://github.com/karma-runner/karma/pull/3719#discussion_r740546736.
- [ ] Remove `parseConfig()` flags introduced in https://github.com/karma-runner/karma/pull/3660 and https://github.com/karma-runner/karma/pull/3635 and enable behavior by default
- [ ] Make `parseConfig()` resolve `configFile` path relative to the CWD instead of relative to the `karma/lib/config.js` to make programmatic API and CLI work the same (https://github.com/karma-runner/karma/issues/1636)
- [ ] Resolve relative plugin paths relative to the `basePath` or CWD for consistent resolution using both CLI and programmatic approaches
- [ ] Remove `jsVersion` configuration property support.
- [ ] Remove `mkdirp` dependency and use [docs](https://nodejs.org/api/fs.html#fsmkdirpath-options-callback) instead (See https://github.com/karma-runner/karma/pull/3750).
- [ ] Include https://github.com/karma-runner/karma/pull/3726.
- [ ] AI in https://github.com/karma-runner/karma/commit/d9dade2f004a340e49c9a633177576200c286404.
- [ ] Consider listening on IPv6 by default. See https://github.com/karma-runner/karma/issues/3730#issuecomment-1128501402.
Contributor guide
Research direction
This is a tracking issue covering browser support, client/karma.js, karma/lib/config.js, dependencies, and several referenced issues and pull requests. Start by selecting one unchecked item and reading its linked issue or pull request plus the relevant entry point. Done is not defined for the overall issue, so confirm the specific scope and acceptance criteria with maintainers before starting.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- testing-qa, tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100