/**
 * TEAM: frontend_infra
 *
 * @flow
 */

// TODO: Fix this eslint issue on next edit. This is an autogenerated comment.
// eslint-disable-next-line flexport/no-legacy-dependencies
import {shallow} from "enzyme";
import FileUploader from "../FileUploader";

const documentTypeList = [
  {label: "Document Type A", value: "document_type_a"},
  {label: "Document Type B", value: "document_type_b"},
  {label: "Document Type E", value: "document_type_e"},
];
describe("FileUploader", () => {
  it("renders simple FileUploader Button", () => {
    const component = shallow(
      <FileUploader onChange={() => {}} documentTypeList={documentTypeList} />
    );
    expect(component).toMatchSnapshot();
  });

  it("renders FileUploader with dropzone when showDropzone={true}", () => {
    const component = shallow(
      <FileUploader
        showDropzone={true}
        onChange={() => {}}
        documentTypeList={documentTypeList}
      />
    );
    expect(component).toMatchSnapshot();
  });
});
