Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sparkeats Specifications #407

Open
yosevu opened this issue Oct 10, 2022 · 0 comments
Open

Sparkeats Specifications #407

yosevu opened this issue Oct 10, 2022 · 0 comments

Comments

@yosevu
Copy link
Contributor

yosevu commented Oct 10, 2022

This will be moved to documentation.

Sparkeats end-to-end specifications are structured as acceptance criteria and organized by page, site header, and site footer.

Conventions

Examples

Location Page

context('Given a user is on a Location Page', () => {
  context('When the user clicks the Sparkeats Logo in the Site Header', () => {
    specify('Then the link goes to the Home Page', () => {
      cy.visit('https://eats.seesparkbox.com/refresh/32');
        // Steps to validate the acceptance criteria
    });
  });
});

Specifications

Site Header

Given a user is on a Location Page
When the user clicks the Logo in the Site Header
Then the link goes to the Home Page

Site Footer

TBD

Home Page

/

  1. Location Menu
Given a user is on the Home Page 
When the user clicks the Locations Menu
Then the Locations Menu opens and the Menu Items are accessible
  1. Location Selection
Given a user has opened the Locations Menu
When the user selects a Menu Item
Then only the Location Cards for the selected location are accessible
  1. New Location
Given a user is on the Home Page 
When the user clicks the Add Location button 
Then the user goes to the Add Location Page
  1. Location Card

Image link

Given a user is on the Home Page 
When the user clicks the image on a Location Card 
Then the user goes to the correct Location Page

Heading link

Given a user is on the Home Page 
When the user clicks the heading on a Location Card 
Then the user goes to the correct Location Page

Heading text

Given a user is on the Home Page 
When the user goes to the heading on a Location Card 
Then the correct heading is accessible

City text

Given a user is on the Home Page 
When the user goes to the city on a Location Card 
Then the correct city is accessible

Region text

Given a user is on the Home Page 
When the user goes to the region on a Location Card 
Then the correct region is accessible

Address text

Given a user is on the Home Page 
When the user goes to the address on a Location Card 
Then the correct address is accessible

Phone text

Given a user is on the Home Page 
When the user goes to the phone on a Location Card 
Then the correct phone is accessible

Site text

Given a user is on the Home Page 
When the user goes to the site on a Location Card 
Then the correct site is accessible

Star rating content

Given a user is on the Home Page 
When the user goes to the star rating on a Location Card 
Then the correct star rating is accessible

Location Page

/locations/:id

Given a user is on the Location Page 
When the user clicks the "Back to home" link
Then the user is directed to the Home page
Given a user is on the Location Page 
When the user clicks the "Add a review" link
Then the user is directed to the New Location page

New Location Page

/locations/new

Given a user is on the New Location Page 
When the user submits the form
Then the user is directed to the Location Page for that location
Given a user submits the New Location Page form
When the user is directed to the Location Page 
Then the user can access the data submitted with the form

New Review Page

/reviews/new

TBD

@yosevu yosevu self-assigned this Oct 10, 2022
@yosevu yosevu removed their assignment Oct 10, 2022
@yosevu yosevu changed the title Sparkeats Specifications How to Write Sparkeats Specifications Oct 10, 2022
@yosevu yosevu changed the title How to Write Sparkeats Specifications How to Write Sparkeats Specifications with Cypress Oct 10, 2022
@yosevu yosevu changed the title How to Write Sparkeats Specifications with Cypress Sparkeats Specifications Oct 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant