Skip to content

Instantly share code, notes, and snippets.

@BrianJenney
Last active August 6, 2021 17:46
Show Gist options
  • Save BrianJenney/94dc377dd4f2af55a990050b07b39dfd to your computer and use it in GitHub Desktop.
Save BrianJenney/94dc377dd4f2af55a990050b07b39dfd to your computer and use it in GitHub Desktop.
it('should show water bottles when a user navigates to `product/water-bottles`', () => {
const { findByText } = renderWithRouterMatch(
<ProductPage />,
{
path: '/:product',
route: '/water-bottles/'
},
{ store = {} }
);
expect(findByText('Purchase Water Bottles')).toBeTruthy();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment