blob: f05159feffacd6747afaabe5d4d6ec42fa2c4a24 (
plain) (
blame)
| 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
 | import React from "react";
import { render } from "@testing-library/react";
import OAuth2Button from "../../components/OAuth2Button";
test("renders oauth2 sign in button text", () => {
    const { getByText } = render(<OAuth2Button />);
    const button = getByText(/Sign in with Discord/i);
    expect(button).toBeInTheDocument();
});
test("renders fontawesome discord icon", () => {
    const { container } = render(<OAuth2Button/>);
    const icon = container.querySelector("[data-icon=\"discord\"]");
    expect(icon).toBeInTheDocument();
});
 |