<commit_before>import { mount } from "enzyme"
import { data as sd } from "sharify"
import React from "react"
import { ModalManager } from "reaction/Components/Authentication/Desktop/ModalManager"
import { ModalContainer } from "../ModalContainer"
import { ContextModule, Intent } from "@artsy/cohesion"
import { ModalType } from "@artsy/reaction/dist/Components/Authentication/Types"
const mediator = require("../../../../lib/mediator.coffee")

jest.mock("sharify")
jest.mock("cookies-js", () => ({
  get: jest.fn(),
  set: jest.fn(),
}))
jest.useFakeTimers()

const cookieSet = require("cookies-js").set as jest.Mock

describe("ModalContainer", () => {
  beforeEach(() => {
    cookieSet.mockClear()
    sd.AP = {
      loginPagePath: "/login",
      signupPagePath: "/signup",
    }
    sd.CSRF_TOKEN = "<PASSWORD>"
  })

  it("Mediator can open a login modal", () => {
    const component = mount(<ModalContainer />)
    mediator.trigger("open:auth", { mode: "login" })<commit_msg>Remove unused CSRF_TOKEN from test.<commit_after>import { mount } from "enzyme"
import { data as sd } from "sharify"
import React from "react"
import { ModalManager } from "reaction/Components/Authentication/Desktop/ModalManager"
import { ModalContainer } from "../ModalContainer"
import { ContextModule, Intent } from "@artsy/cohesion"
import { ModalType } from "@artsy/reaction/dist/Components/Authentication/Types"
const mediator = require("../../../../lib/mediator.coffee")

jest.mock("sharify")
jest.mock("cookies-js", () => ({
  get: jest.fn(),
  set: jest.fn(),
}))
jest.useFakeTimers()

const cookieSet = require("cookies-js").set as jest.Mock

describe("ModalContainer", () => {
  beforeEach(() => {
    cookieSet.mockClear()
    sd.AP = {
      loginPagePath: "/login",
      signupPagePath: "/signup",
    }
  })

  it("Mediator can open a login modal", () => {
    const component = mount(<ModalContainer />)
    mediator.trigger("open:auth", { mode: "login" })
{'fraction_non_alphanumeric': 0.17322432294328052, 'fraction_numerical': 0.0, 'mean_word_length': 4.046391752577319, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 14, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3525714', 'n_tokens_mistral': 632, 'n_tokens_neox': 607, 'n_words': 138}