Skip to content

Commit

Permalink
Fix Molecules & Organisms
Browse files Browse the repository at this point in the history
  • Loading branch information
AndyEPhipps committed Sep 27, 2023
1 parent 3a51f65 commit bce559e
Show file tree
Hide file tree
Showing 30 changed files with 92 additions and 1 deletion.
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/accordion.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('Accordion component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#accordion');
cy.get('[data-testid="Accordion-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('Accordion component', () => {

describe('Accordion section', () => {
beforeEach(() => {
cy.visit('/#accordion');
cy.get('[data-testid="Accordion-example-1"]')
.as('container')
.find('[data-preview="Accordion"]')
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/articleTeaser.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('ArticleTeaser component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#articleteaser');
cy.get('[data-testid="ArticleTeaser-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('ArticleTeaser component', () => {

describe('Article Teaser section', () => {
beforeEach(() => {
cy.visit('/#articleteaser');
cy.get('[data-testid="ArticleTeaser-example-1"]')
.as('container')
.find('[data-preview="ArticleTeaser"]')
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/banner.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('Banner component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#banner');
cy.get('[data-testid="Banner-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('Banner component', () => {

describe('Banner section', () => {
beforeEach(() => {
cy.visit('/#banner');
cy.get('[data-testid="Banner-example-1"]')
.as('container')
.find('[data-preview="Banner"]')
Expand Down
3 changes: 3 additions & 0 deletions cypress/e2e/components/molecules/box.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('Box component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#box');
cy.get('[data-testid="Box-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('Box component', () => {

describe('Box example 1 section', () => {
beforeEach(() => {
cy.visit('/#box');
cy.get('[data-testid="Box-example-1"]')
.as('container')
.find('[data-preview="Box"]')
Expand Down Expand Up @@ -71,6 +73,7 @@ describe('Box component', () => {

describe('Box example 3 section', () => {
beforeEach(() => {
cy.visit('/#box');
cy.get('[data-testid="Box-example-3"]')
.as('container')
.find('[data-preview="Box"]')
Expand Down
3 changes: 3 additions & 0 deletions cypress/e2e/components/molecules/card.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ describe('Card component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#card');
cy.get('[data-testid="Card-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -36,6 +37,7 @@ describe('Card component', () => {

describe('Card example 1 section', () => {
beforeEach(() => {
cy.visit('/#card');
cy.get('[data-testid="Card-example-1"]')
.as('container')
.find('[data-preview="Card"]')
Expand Down Expand Up @@ -72,6 +74,7 @@ describe('Card component', () => {

describe('Card no body section', () => {
beforeEach(() => {
cy.visit('/#card');
cy.get('[data-testid="Card-example-3"]')
.as('container')
.find('[data-preview="Card"]')
Expand Down
6 changes: 5 additions & 1 deletion cypress/e2e/components/molecules/cardDs.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ describe('CardDs component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#cardds');
cy.get('[data-testid="CardDs-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -36,6 +37,7 @@ describe('CardDs component', () => {

describe('CardDs image and CTA section', () => {
beforeEach(() => {
cy.visit('/#cardds');
cy.get('[data-testid="CardDs-example-1"]')
.as('container')
.find('[data-preview="CardDs"]')
Expand Down Expand Up @@ -79,6 +81,7 @@ describe('CardDs component', () => {

describe('CardDs no Image with link section', () => {
beforeEach(() => {
cy.visit('/#cardds');
cy.get('[data-testid="CardDs-example-3"]')
.as('container')
.find('[data-preview="CardDs"]')
Expand Down Expand Up @@ -122,6 +125,7 @@ describe('CardDs component', () => {

describe('CardDs no image no link section', () => {
beforeEach(() => {
cy.visit('/#cardds');
cy.get('[data-testid="CardDs-example-5"]')
.as('container')
.find('[data-preview="CardDs"]')
Expand Down Expand Up @@ -154,7 +158,7 @@ describe('CardDs component', () => {

describe('CardDs image, text, no link', () => {
beforeEach(() => {
// Here
cy.visit('/#cardds');
cy.get('[data-testid="CardDs-example-7"]')
.as('container')
.find('[data-preview="CardDs"]')
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/chip.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ describe('Chip component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#chip');
cy.get('[data-testid="Chip-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -36,6 +37,7 @@ describe('Chip component', () => {

describe('Chip section', () => {
beforeEach(() => {
cy.visit('/#chip');
cy.get('[data-testid="Chip-example-1"]')
.as('container')
.find('[data-preview="Chip"]')
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/countdown.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ describe('Countdown component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#countdown');
cy.get('[data-testid="Countdown-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -36,6 +37,7 @@ describe('Countdown component', () => {

describe('Countdown section', () => {
beforeEach(() => {
cy.visit('/#countdown');
cy.get('[data-testid="Countdown-examples"]')
.find('p')
.contains('Limit is 365 days');
Expand Down
3 changes: 3 additions & 0 deletions cypress/e2e/components/molecules/descriptor.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ describe('Descriptor component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#descriptor');
cy.get('[data-testid="Descriptor-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -36,6 +37,7 @@ describe('Descriptor component', () => {

describe('Descriptor section: Descriptor-example-1', () => {
beforeEach(() => {
cy.visit('/#descriptor');
cy.get('[data-testid="Descriptor-examples"]')
.find('h3')
.contains('Descriptor Component');
Expand Down Expand Up @@ -86,6 +88,7 @@ describe('Descriptor component', () => {

describe('Descriptor section: Descriptor-example-2', () => {
beforeEach(() => {
cy.visit('/#descriptor');
cy.get('[data-testid="Descriptor-examples"]')
.find('h3')
.contains('Descriptor Component');
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/doubleCopy.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('DoubleCopy component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#doublecopy');
cy.get('[data-testid="DoubleCopy-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('DoubleCopy component', () => {

describe('DoubleCopy section', () => {
beforeEach(() => {
cy.visit('/#doublecopy');
cy.get('[data-testid="DoubleCopy-example-1"]')
.as('container')
.find('[data-preview="DoubleCopy"]')
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/heroBanner.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('Herobanner component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#herobanner');
cy.get('[data-testid="HeroBanner-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('Herobanner component', () => {

describe('HeroBanner section', () => {
beforeEach(() => {
cy.visit('/#herobanner');
cy.get('[data-testid="HeroBanner-example-1"]')
.as('container')
.find('[data-preview="HeroBanner"]')
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/infoBanner.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('infobanner component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#infobanner');
cy.get('[data-testid="InfoBanner-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('infobanner component', () => {

describe('Infobanner section', () => {
beforeEach(() => {
cy.visit('/#infobanner');
cy.get('[data-testid="InfoBanner-example-1"]')
.as('container')
.find('[data-preview="InfoBanner"]')
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/partnerLink.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('PartnerLink component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#partnerlink');
cy.get('[data-testid="PartnerLink-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('PartnerLink component', () => {

describe('Partnerlink section', () => {
beforeEach(() => {
cy.visit('/#partnerlink');
cy.get('[data-testid="PartnerLink-example-1"]')
.as('container')
.find('[data-preview="PartnerLink"]')
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/promo.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('Promo component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#promo');
cy.get('[data-testid="Promo-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('Promo component', () => {

describe('Promo section', () => {
beforeEach(() => {
cy.visit('/#promo');
cy.get('[data-testid="Promo-example-1"]')
.as('container')
.find('[data-preview="Promo"]')
Expand Down
3 changes: 3 additions & 0 deletions cypress/e2e/components/molecules/schoolLookup.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('School Lookup component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#schoollookup');
cy.get('[data-testid="SchoolLookup-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('School Lookup component', () => {

describe('view code section', () => {
beforeEach(() => {
cy.visit('/#schoollookup');
cy.get('[data-testid="SchoolLookup-example-1"]')
.as('container')
.find('[data-preview="SchoolLookup"]')
Expand All @@ -60,6 +62,7 @@ describe('School Lookup component', () => {

describe('School lookup functionality', () => {
beforeEach(() => {
cy.visit('/#schoollookup');
cy.get('[data-testid="SchoolLookup-example-1"]')
.as('container')
.find('[data-preview="SchoolLookup"]')
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/searchInput.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('Search Input component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#searchinput');
cy.get('[data-testid="SearchInput-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('Search Input component', () => {

describe('Search Input section', () => {
beforeEach(() => {
cy.visit('/#searchinput');
cy.get('[data-testid="SearchInput-example-1"]')
.as('container')
.find('[data-preview="SearchInput"]')
Expand Down
5 changes: 5 additions & 0 deletions cypress/e2e/components/molecules/searchResult.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('Search Result component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#searchresult');
cy.get('[data-testid="SearchResult-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('Search Result component', () => {

describe('Search Result Minimalist section', () => {
beforeEach(() => {
cy.visit('/#searchresult');
cy.get('[data-testid="SearchResult-example-1"]')
.as('container')
.find('[data-preview="SearchResult"]')
Expand Down Expand Up @@ -69,6 +71,7 @@ describe('Search Result component', () => {

describe('Search Result with copy section', () => {
beforeEach(() => {
cy.visit('/#searchresult');
cy.get('[data-testid="SearchResult-example-3"]')
.as('container')
.find('[data-preview="SearchResult"]')
Expand Down Expand Up @@ -106,6 +109,7 @@ describe('Search Result component', () => {

describe('Search Result with date section', () => {
beforeEach(() => {
cy.visit('/#searchresult');
cy.get('[data-testid="SearchResult-example-5"]')
.as('container')
.find('[data-preview="SearchResult"]')
Expand Down Expand Up @@ -146,6 +150,7 @@ describe('Search Result component', () => {

describe('Search Result with date and type section', () => {
beforeEach(() => {
cy.visit('/#searchresult');
cy.get('[data-testid="SearchResult-example-5"]')
.as('container')
.find('[data-preview="SearchResult"]')
Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/components/molecules/shareButton.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('Share Button component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#sharebutton');
cy.get('[data-testid="ShareButton-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('Share Button component', () => {

describe('Share Button section', () => {
beforeEach(() => {
cy.visit('/#sharebutton');
cy.get('[data-testid="ShareButton-example-0"]')
.as('container')
.find('[data-preview="ShareButton"]')
Expand Down
3 changes: 3 additions & 0 deletions cypress/e2e/components/molecules/simpleSchoolLookup.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ describe('SimpleSchoolLookup component', () => {

describe('props and methods section', () => {
beforeEach(() => {
cy.visit('/#simpleschoollookup');
cy.get('[data-testid="SimpleSchoolLookup-container"] button[name="rsg-usage"]')
.contains('Props & methods')
.as('propsBtn');
Expand Down Expand Up @@ -35,6 +36,7 @@ describe('SimpleSchoolLookup component', () => {

describe('view code section', () => {
beforeEach(() => {
cy.visit('/#simpleschoollookup');
cy.get('[data-testid="SimpleSchoolLookup-examples"]')
.as('container');

Expand All @@ -58,6 +60,7 @@ describe('SimpleSchoolLookup component', () => {

describe('Simple School lookup functionality', () => {
beforeEach(() => {
cy.visit('/#simpleschoollookup');
cy.get('[data-testid="SimpleSchoolLookup-example-0"]')
.as('container')
.find('[data-preview="SimpleSchoolLookup"]')
Expand Down
Loading

0 comments on commit bce559e

Please sign in to comment.