mirror of
https://github.com/DOI-DO/j40-cejst-2.git
synced 2025-02-23 01:54:18 -08:00
28 lines
553 B
JavaScript
28 lines
553 B
JavaScript
|
const React = require('react');
|
||
|
const gatsby = jest.requireActual('gatsby');
|
||
|
|
||
|
module.exports = {
|
||
|
...gatsby,
|
||
|
graphql: jest.fn(),
|
||
|
Link: jest.fn().mockImplementation(
|
||
|
// these props are invalid for an `a` tag
|
||
|
({
|
||
|
activeClassName,
|
||
|
activeStyle,
|
||
|
getProps,
|
||
|
innerRef,
|
||
|
partiallyActive,
|
||
|
ref,
|
||
|
replace,
|
||
|
to,
|
||
|
...rest
|
||
|
}) =>
|
||
|
React.createElement('a', {
|
||
|
...rest,
|
||
|
href: to,
|
||
|
}),
|
||
|
),
|
||
|
StaticQuery: jest.fn(),
|
||
|
useStaticQuery: jest.fn(),
|
||
|
};
|