Skip to content

Commit

Permalink
fix(author): adjust heaviside
Browse files Browse the repository at this point in the history
  • Loading branch information
duncdrum committed Feb 29, 2024
1 parent 1ea5a45 commit 520ee3f
Showing 1 changed file with 16 additions and 6 deletions.
22 changes: 16 additions & 6 deletions cypress/e2e/author.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -142,21 +142,31 @@ describe('Author Search', () => {
url: '/Results',
qs: {
lookfor: 'oliver heaviside',
type: 'allFields'
type: 'allFields',
limit: 5
}
})
})

it('should appear in each of top 20', () => {
it('should appear in titles or decscription', () => {
cy.get('.resultlist')
.each(($el, index, $lis) => {
cy.wrap($el)
if ($el.text().includes('Oliver Heaviside')) {
cy.get($el)
.contains('Heaviside', {matchCase: false})
} else {
cy.get($el)
.click()
cy.get('.long-view')
.find('a[id^=description_]')
.click()
cy.get('.additional')
.contains('Heaviside', {matchCase: false})
}

})
.then(($lis) => {
cy.wrap($lis)
.should('have.length', '20')
})

})
})
})
Expand Down

0 comments on commit 520ee3f

Please sign in to comment.