# @k8slens/jest

> Jest configuration and scripts for Lens packages.

Latest version **6.5.0** (published 2023-05-26) · MIT license · 0 weekly downloads

## Install

```sh
npm install @k8slens/jest
pnpm add @k8slens/jest
yarn add @k8slens/jest
bun add @k8slens/jest
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: no vulnerabilities; popular repo.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 6.5.0 |
| Published | 2023-05-26 |
| First published | 2023-02-24 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 10 |
| Unpacked size | 8.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 23247 |
| Author | OpenLens Authors |
| Maintainers | mirantis_it, jakolehm, k8slens-bot |

## Links

- npm: https://www.npmjs.com/package/@k8slens/jest
- Repository: https://github.com/lensapp/lens
- Issues: https://github.com/lensapp/lens/issues
- npm.io page: https://npm.io/package/@k8slens/jest

## Dependencies (10)

- [jest](https://npm.io/package/jest.md) ^29.5.0
- [lodash](https://npm.io/package/lodash.md) ^4.17.21
- [ts-jest](https://npm.io/package/ts-jest.md) ^29.0.3
- [@types/jest](https://npm.io/package/@types/jest.md) ^29.2.2
- [identity-obj-proxy](https://npm.io/package/identity-obj-proxy.md) ^3.0.0
- [jest-watch-typeahead](https://npm.io/package/jest-watch-typeahead.md) ^2.2.1
- [@testing-library/react](https://npm.io/package/@testing-library/react.md) ^12.1.5
- [jest-environment-jsdom](https://npm.io/package/jest-environment-jsdom.md) ^29.5.0
- [@testing-library/jest-dom](https://npm.io/package/@testing-library/jest-dom.md) ^5.16.5
- [jest-watch-select-projects](https://npm.io/package/jest-watch-select-projects.md) ^2.0.0

## Recent versions

- 6.5.0 (latest) — 2023-05-26
- 6.5.0-alpha.5 (alpha) — 2023-05-04
- 6.5.0-cron.e6d6d1d (cron) — 2023-03-10
- 6.5.0-alpha.4 — 2023-04-20
- 6.5.0-alpha.3 — 2023-04-18
- 6.5.0-alpha.2 — 2023-04-12
- 6.5.0-alpha.1 — 2023-03-14
- 6.5.0-cron.48ce558 — 2023-03-09
- 6.5.0-cron.094758f — 2023-03-08
- 6.5.0-cron.f88555a — 2023-03-07
- 6.5.0-cron.a917494 — 2023-03-06
- 6.5.0-cron.ab11b20 — 2023-03-03
- 6.4.0-cron.6df01ba — 2023-03-02
- 6.4.0-cron.ec81af4 — 2023-03-01
- 6.4.0-cron.d29615c — 2023-02-28
- … 2 more at https://npm.io/package/@k8slens/jest/versions

## README

# @k8slens/jest

This package contains jest configurations and scripts for Lens packages.

## Install

```
$ npm install @k8slens/jest
```

## Features

### Package configurations
Shared configurations for minimal duplication.

#### Node

**./packages/<any-package>/jest.config.js**
```javascript
module.exports = require("@k8slens/jest").monorepoPackageConfig(__dirname).configForNode;
```

#### React

**./packages/<any-package>/jest.config.js**
```javascript
module.exports = require("@k8slens/jest").monorepoPackageConfig(__dirname).configForReact;
```

### Root configuration
You may want to enable testing of packages using single command from root level. This allows you to utilize `jest --watch` between all packages.


**./jest.config.js**
```javascript
module.exports = require("@k8slens/jest").monorepoRootConfig(__dirname);
```

### Scripts

#### lens-test
Test package with coverage enforcement. Automatically opens coverage report in case of failure.

**./packages/<any-package>/package.json**
```json
{
 "scripts": {
   "test": "lens-test"
 }         
}
```

---
_Source: https://npm.io/package/@k8slens/jest · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
