UNPKG

@jjordy/swr-devtools

Version:

Devtools for SWR

14 lines (13 loc) 517 B
import React from "react"; import SWRDevtools from "."; import { describe, test, expect } from "@jest/globals"; import { render, screen } from "../test-utils"; describe("SWR Devtools", () => { test("Should render a component", async () => { expect.assertions(1); render(React.createElement(SWRDevtools, null, "Hello WOrld")); const title = await screen.getByTitle("Open SWR Devtools"); //@ts-ignore expect(title).toHaveTextContent("SWR DEVTOOLS"); }); });