opinion-ateTDD_personal/cypress/e2e/listing-restaurants.cy.js

16 lines
451 B
JavaScript
Raw Normal View History

2024-04-24 15:21:01 -04:00
describe('Listing Restaurants', () => {
it('shows restaurants from the server', () => {
2024-04-24 11:35:35 -04:00
const sushiPlace = "Sushi Place";
const pizzaPlace = "Pizza Place";
cy.intercept('GET', 'https://api.outsidein.dev/*/restaurants',
[
{id: 850, name: sushiPlace},
{id: 851, name: pizzaPlace}
]);
cy.visit('/');
cy.contains(sushiPlace);
cy.contains(pizzaPlace);
})
})