<commit_before>import { shallow } from "enzyme";
import { DOM, createElement } from "react";

import { Map, MapProps } from "../Map";

import { EventMock, GeocoderLocationType, GeocoderMock, GeocoderStatus, LatLngBoundsMock,
    LatLngMock, MapsMock, MarkerMock } from "../../../../../../../tests/mocks/GoogleMaps";

describe("Map", () => {

    window.google = window.google || {};
    window.google.maps = window.google.maps || {};
    window.google.event = window.google.event || {};
    const originalMap = window.google.maps.Map;
    const originalGeocoder = window.google.maps.Geocoder;
    const originalLatLngBounds = window.google.maps.LatLngBounds;
    const originalLatLng = window.google.maps.LatLng;
    const originalMarker = window.google.maps.Marker;
    const originalEvent = window.google.maps.event;

    const address = "Lumumba Ave, Kampala, Uganda";


    beforeEach(() => {
        window.google.maps.Geocoder = GeocoderMock;
        window.google.maps.Map = MapsMock;
        window.google.maps.LatLngBounds = LatLngBoundsMock;
        window.google.maps.LatLng = LatLngMock;
        window.google.maps.Marker = MarkerMock;
        window.google.maps.event = EventMock;
        window.google.maps.GeocoderStatus = GeocoderStatus;
        window.google.maps.GeocoderStatus = GeocoderLocationType;
    });

    it("should render with the map structure", () => {
         const renderMap = (props: MapProps) => shallow(createElement(Map, props));
         const output = renderMap({ address })
         expect(output).toMatchStructure(
            DOM.div({ })
          );
    });

    it("renders with classes", () => { // test against mx-google-maps
        // 
    });

    it("should load the google maps script with API key", () => {
        //
    });

    it("should load the google maps script without API key", () => {
        //
    });

    it("should add a resize listener", () => {
        //<commit_msg>Tests that structure has class<commit_after>import { shallow } from "enzyme";
import { DOM, createElement } from "react";

import { Map, MapProps } from "../Map";

import { EventMock, GeocoderLocationType, GeocoderMock, GeocoderStatus, LatLngBoundsMock,
    LatLngMock, MapsMock, MarkerMock } from "../../../../../../../tests/mocks/GoogleMaps";

describe("Map", () => {

    window.google = window.google || {};
    window.google.maps = window.google.maps || {};
    window.google.event = window.google.event || {};
    const originalMap = window.google.maps.Map;
    const originalGeocoder = window.google.maps.Geocoder;
    const originalLatLngBounds = window.google.maps.LatLngBounds;
    const originalLatLng = window.google.maps.LatLng;
    const originalMarker = window.google.maps.Marker;
    const originalEvent = window.google.maps.event;

    const address = "Lumumba Ave, Kampala, Uganda";
    const renderMap = (props: MapProps) => shallow(createElement(Map, props));
    const output = renderMap({ address });

    beforeEach(() => {
        window.google.maps.Geocoder = GeocoderMock;
        window.google.maps.Map = MapsMock;
        window.google.maps.LatLngBounds = LatLngBoundsMock;
        window.google.maps.LatLng = LatLngMock;
        window.google.maps.Marker = MarkerMock;
        window.google.maps.event = EventMock;
        window.google.maps.GeocoderStatus = GeocoderStatus;
        window.google.maps.GeocoderStatus = GeocoderLocationType;
    });

    it("should render with the map structure", () => {
         expect(output).toMatchStructure(
            DOM.div({ })
          );
    });

    it("renders with classes", () => {
        expect(output).toHaveClass("mx-google-maps");
    });

    it("should load the google maps script with API key", () => {
        //
    });

    it("should load the google maps script without API key", () => {
        //
    });

    it("should add a resize listener", () => {
        //
{'fraction_non_alphanumeric': 0.14348049281314168, 'fraction_numerical': 0.0, 'mean_word_length': 2.761583011583012, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 19, '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': '3019889', 'n_tokens_mistral': 1160, 'n_tokens_neox': 1130, 'n_words': 242}