mirror of
https://github.com/LukeHagar/unicorn-utterances.git
synced 2025-12-10 04:22:06 +00:00
16 lines
337 B
JavaScript
16 lines
337 B
JavaScript
import React from 'react'
|
|
import {onLinkClick} from 'gatsby-plugin-google-analytics';
|
|
|
|
afterEach(() => {
|
|
onLinkClick.mockReset();
|
|
})
|
|
|
|
jest.mock('gatsby-plugin-google-analytics', () => {
|
|
const onLinkClick = jest.fn();
|
|
|
|
return {
|
|
OutboundLink: (props) => <div onClick={onLinkClick}>{props.children}</div>,
|
|
onLinkClick
|
|
}
|
|
});
|