mirror of
https://github.com/AmruthPillai/Reactive-Resume.git
synced 2025-11-15 01:01:43 +10:00
36 lines
668 B
JavaScript
36 lines
668 B
JavaScript
const React = require(`react`);
|
|
const gatsby = jest.requireActual(`gatsby`);
|
|
|
|
module.exports = {
|
|
...gatsby,
|
|
graphql: jest.fn(),
|
|
Link: jest.fn().mockImplementation(({ to, ...rest }) =>
|
|
React.createElement(`a`, {
|
|
...rest,
|
|
href: to,
|
|
}),
|
|
),
|
|
StaticQuery: jest.fn(),
|
|
useStaticQuery: jest.fn().mockReturnValue({
|
|
site: {
|
|
siteMetadata: {
|
|
title: '',
|
|
description: '',
|
|
author: '',
|
|
siteUrl: '',
|
|
},
|
|
},
|
|
file: {
|
|
childImageSharp: {
|
|
fluid(maxWidth = 512) {
|
|
base64;
|
|
aspectRatio;
|
|
src;
|
|
srcSet;
|
|
sizes;
|
|
},
|
|
},
|
|
},
|
|
}),
|
|
};
|