Skip to content
Permalink
Browse files

test(gatsby-ssr spec): added a test for /page-data/ JSON files being …

…removed
  • Loading branch information
itmayziii committed Oct 1, 2019
1 parent 7b7f5a4 commit f3faf88a317ca73710dbe978d1cfd2c2ca89954d
Showing with 14 additions and 1 deletion.
  1. +13 −0 src/fake-data.spec.ts
  2. +1 −1 src/gatsby-ssr.spec.ts
@@ -161,6 +161,19 @@ export const headComponentsData = [
crossOrigin: 'use-credentials'
},
_owner: null
},
{ // 15
type: 'link',
key: '/page-data/welcome/page-data.json',
ref: null,
props:
{
as: 'fetch',
rel: 'preload',
href: '/page-data/welcome/page-data.json',
crossOrigin: 'use-credentials'
},
_owner: null
}
]

@@ -60,7 +60,7 @@ describe('gatsby-ssr.js', (): void => {

onRenderBody({ scripts: [] })
function getHeadComponents (): ReactNode[] {
return [headComponentsData[0], headComponentsData[1], headComponentsData[14]]
return [headComponentsData[0], headComponentsData[1], headComponentsData[14], headComponentsData[15]]
}
function getPostBodyComponents (): ReactNode[] {
return []

0 comments on commit f3faf88

Please sign in to comment.
You can’t perform that action at this time.