preact-hooks-testing-library icon indicating copy to clipboard operation
preact-hooks-testing-library copied to clipboard

Simple and complete Preact hooks testing utilities that encourage good testing practices.

Results 10 preact-hooks-testing-library issues
Sort by recently updated
recently updated
newest added

Hey there guys, I am trying to test some of my custom hooks that work in prod, but don't work with @testing-library/preact-hooks. I am trying to write some unit tests...

Getting this error when running `npm install` & `npm ci` using npm 8.12.1: ``` npm ERR! code ERESOLVE npm ERR! ERESOLVE could not resolve npm ERR! npm ERR! While resolving:...

Now that https://github.com/testing-library/preact-testing-library/issues/56 is merged, this library can be deprecated CC/ @testing-library/preact-hooks

documentation

Fixes in this PR get the typing closer to what React's testing library does and thereby makes migrations from React to Preact easier. When I migrated from React to Preact,...

The `lib` project is being generated when building the code but we don't want it to be committed. So let's ignore it properly.

**What**: Upgrade to Jest 27 **Why**: Ensuring compatibility with breaking changes in Jest 27 **How**: Upgrading packages and manually setting `testEnvironment` to `jsdom`

Mistakenly left in #9 All tests still pass. The `wait` deprecation message now logs directly to the terminal output in the course of running the tests. While not ideal, this...

```js import React from "preact/compat"; import { act, renderHook } from "@testing-library/preact-hooks"; // works: // import React from "react"; // import { act, renderHook } from "@testing-library/react-hooks"; function useTest() {...

```jsx import React from "preact/compat"; import { act, renderHook } from "@testing-library/preact-hooks"; // works: // import React from "react"; // import { act, renderHook } from "@testing-library/react-hooks"; function useTest() {...