https://github.com/maxdeviant/node-openid-client-is-plain-object-repro
A reproduction of an issue with `openid-client` and (seemingly) Jest
https://github.com/maxdeviant/node-openid-client-is-plain-object-repro
Last synced: 8 months ago
JSON representation
A reproduction of an issue with `openid-client` and (seemingly) Jest
- Host: GitHub
- URL: https://github.com/maxdeviant/node-openid-client-is-plain-object-repro
- Owner: maxdeviant
- Created: 2022-11-23T19:55:37.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2023-04-18T16:26:09.000Z (almost 3 years ago)
- Last Synced: 2025-04-09T15:20:39.281Z (11 months ago)
- Language: TypeScript
- Size: 67.4 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# node-openid-client-is-plain-object-repro
This is a repository showcasing an issue when using `openid-client` together with Jest.
## Setup
Install the dependencies:
```
yarn
```
## Running the Tests
This repository has tests setup with both Jest and Mocha to isolate the issue to Jest.
### Jest
```
yarn test:jest
```
One of the Jest tests should fail:
```
Repro: Jest
buildClient
when not using a workaround
✕ returns the constructed client (176 ms)
when using a workaround
✓ returns the constructed client (107 ms)
```
### Mocha
```
yarn test:mocha
```
The Mocha tests will both pass:
```
Repro: Mocha
buildClient
when not using a workaround
✔ returns the constructed client (141ms)
when using a workaround
✔ returns the constructed client (114ms)
```
### Vitest
```
yarn test:vitest
```
The Vitest tests will both pass:
```
✓ src/index.vitest.test.ts (2)
Test Files 1 passed (1)
Tests 2 passed (2)
Start at 12:24:54
Duration 1.36s (transform 89ms, setup 0ms, collect 290ms, tests 198ms, environment 0ms, prepare 120ms)
```