(id: string, hero?: PostHero | null)
| 1835 | const sourceFixture = defaultFeedPage.edges[0].node.source; |
| 1836 | |
| 1837 | const buildPost = (id: string, hero?: PostHero | null): Post => |
| 1838 | ({ |
| 1839 | id, |
| 1840 | title: `Post ${id}`, |
| 1841 | createdAt: '2026-05-25T00:00:00.000Z', |
| 1842 | image: 'https://daily.dev/img.png', |
| 1843 | readTime: 1, |
| 1844 | source: sourceFixture, |
| 1845 | tags: [], |
| 1846 | permalink: `http://localhost:4000/r/${id}`, |
| 1847 | numComments: 0, |
| 1848 | numUpvotes: 0, |
| 1849 | commentsPermalink: `http://localhost:5002/posts/${id}`, |
| 1850 | read: false, |
| 1851 | upvoted: false, |
| 1852 | commented: false, |
| 1853 | type: PostType.Article, |
| 1854 | domain: 'example.com', |
| 1855 | hero: hero ?? null, |
| 1856 | } as Post); |
| 1857 | |
| 1858 | const SIGNIFICANCE_BY_SIZE: Record<number, PostHeroSignificance> = { |
| 1859 | 4: 'breaking', |
no outgoing calls
no test coverage detected