mirror of
				https://github.com/mastermindzh/rickvanlieshout.com
				synced 2025-11-04 10:40:09 +01:00 
			
		
		
		
	test: add fixtures
This commit is contained in:
		
							
								
								
									
										46
									
								
								jest/__fixtures__/all-markdown-remark.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										46
									
								
								jest/__fixtures__/all-markdown-remark.js
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,46 @@
 | 
			
		||||
'use strict';
 | 
			
		||||
 | 
			
		||||
module.exports = {
 | 
			
		||||
  allMarkdownRemark: {
 | 
			
		||||
    group: [
 | 
			
		||||
      {
 | 
			
		||||
        fieldValue: 'test_0',
 | 
			
		||||
        totalCount: 1
 | 
			
		||||
      },
 | 
			
		||||
      {
 | 
			
		||||
        fieldValue: 'test_1',
 | 
			
		||||
        totalCount: 2
 | 
			
		||||
      }
 | 
			
		||||
    ],
 | 
			
		||||
    edges: [
 | 
			
		||||
      {
 | 
			
		||||
        node: {
 | 
			
		||||
          fields: {
 | 
			
		||||
            slug: '/test_0',
 | 
			
		||||
            categorySlug: '/test'
 | 
			
		||||
          },
 | 
			
		||||
          frontmatter: {
 | 
			
		||||
            date: '2016-09-01',
 | 
			
		||||
            description: 'test_0',
 | 
			
		||||
            category: 'test',
 | 
			
		||||
            title: 'test_0'
 | 
			
		||||
          }
 | 
			
		||||
        }
 | 
			
		||||
      },
 | 
			
		||||
      {
 | 
			
		||||
        node: {
 | 
			
		||||
          fields: {
 | 
			
		||||
            slug: '/test_1',
 | 
			
		||||
            categorySlug: '/test'
 | 
			
		||||
          },
 | 
			
		||||
          frontmatter: {
 | 
			
		||||
            date: '2016-09-01',
 | 
			
		||||
            description: 'test_1',
 | 
			
		||||
            category: 'test',
 | 
			
		||||
            title: 'test_1'
 | 
			
		||||
          }
 | 
			
		||||
        }
 | 
			
		||||
      }
 | 
			
		||||
    ]
 | 
			
		||||
  }
 | 
			
		||||
};
 | 
			
		||||
							
								
								
									
										22
									
								
								jest/__fixtures__/markdown-remark.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										22
									
								
								jest/__fixtures__/markdown-remark.js
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,22 @@
 | 
			
		||||
'use strict';
 | 
			
		||||
 | 
			
		||||
module.exports = {
 | 
			
		||||
  markdownRemark: {
 | 
			
		||||
    html: '<p>test</p>',
 | 
			
		||||
    fields: {
 | 
			
		||||
      tagSlugs: [
 | 
			
		||||
        '/test_0',
 | 
			
		||||
        '/test_1'
 | 
			
		||||
      ]
 | 
			
		||||
    },
 | 
			
		||||
    frontmatter: {
 | 
			
		||||
      date: '2016-09-01',
 | 
			
		||||
      description: 'test',
 | 
			
		||||
      title: 'test',
 | 
			
		||||
      tags: [
 | 
			
		||||
        'test_0',
 | 
			
		||||
        'test_1'
 | 
			
		||||
      ]
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
};
 | 
			
		||||
							
								
								
									
										13
									
								
								jest/__fixtures__/page-context.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								jest/__fixtures__/page-context.js
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,13 @@
 | 
			
		||||
'use strict';
 | 
			
		||||
 | 
			
		||||
module.exports = {
 | 
			
		||||
  pageContext: {
 | 
			
		||||
    tag: 'test',
 | 
			
		||||
    category: 'test',
 | 
			
		||||
    currentPage: 1,
 | 
			
		||||
    prevPagePath: '/page/1',
 | 
			
		||||
    nextPagePath: '/page/3',
 | 
			
		||||
    hasNextPage: true,
 | 
			
		||||
    hasPrevPage: true
 | 
			
		||||
  }
 | 
			
		||||
};
 | 
			
		||||
							
								
								
									
										41
									
								
								jest/__fixtures__/site-metadata.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										41
									
								
								jest/__fixtures__/site-metadata.js
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,41 @@
 | 
			
		||||
'use strict';
 | 
			
		||||
 | 
			
		||||
module.exports = {
 | 
			
		||||
  site: {
 | 
			
		||||
    siteMetadata: {
 | 
			
		||||
      url: 'http://localhost',
 | 
			
		||||
      title: 'Test title',
 | 
			
		||||
      subtitle: 'Test subtitle',
 | 
			
		||||
      copyright: 'Test copyright',
 | 
			
		||||
      disqusShortname: '',
 | 
			
		||||
      postsPerPage: 4,
 | 
			
		||||
      menu: [
 | 
			
		||||
        {
 | 
			
		||||
          label: 'Test label 1',
 | 
			
		||||
          path: '/test/1/'
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          label: 'Test label 2',
 | 
			
		||||
          path: '/test/2/'
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          label: 'Test label 3',
 | 
			
		||||
          path: '/test/3/'
 | 
			
		||||
        }
 | 
			
		||||
      ],
 | 
			
		||||
      author: {
 | 
			
		||||
        name: 'Test name',
 | 
			
		||||
        photo: '/test.jpg',
 | 
			
		||||
        bio: 'Test bio',
 | 
			
		||||
        contacts: {
 | 
			
		||||
          email: '#',
 | 
			
		||||
          telegram: '#',
 | 
			
		||||
          twitter: '#',
 | 
			
		||||
          github: '#',
 | 
			
		||||
          rss: '#',
 | 
			
		||||
          vkontakte: '#'
 | 
			
		||||
        }
 | 
			
		||||
      }
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
};
 | 
			
		||||
		Reference in New Issue
	
	Block a user