Attempt to test Builder, using DatabaseContext mock.

This commit is contained in:
gianantoniopini
2020-12-10 11:13:03 +01:00
parent 435400b1e3
commit 9736b2c6d4
5 changed files with 115 additions and 1 deletions

View File

@ -11,5 +11,25 @@ module.exports = {
}),
),
StaticQuery: jest.fn(),
useStaticQuery: jest.fn(),
useStaticQuery: jest.fn().mockReturnValue({
site: {
siteMetadata: {
title: '',
description: '',
author: '',
siteUrl: '',
},
},
file: {
childImageSharp: {
fluid(maxWidth = 512) {
base64;
aspectRatio;
src;
srcSet;
sizes;
},
},
},
}),
};