Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import React from "react";
- import { render, cleanup, fireEvent } from "@testing-library/react";
- import Sum from "./Sum";
- describe("Sum", () => {
- it('should have two inputs to add the numbers', () => {
- const { getByTestId } = render(<Sum />);
- const firstInput = getByTestId("value1");
- const secondInput = getByTestId("value2");
- expect(firstInput).toBeTruthy();
- expect(secondInput).toBeTruthy();
- });
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement