diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index d7a1be5..d95d68f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -26,8 +26,10 @@ jobs: config: baseUrl=https://stabikat.de/search/ spec: | cypress/e2e/spec.cy.js + cypress/e2e/author.cy.js cypress/e2e/reviews.cy.js cypress/e2e/nested.cy.js + cypress/e2e/multi-lang-phrase.cy.js # browser: firefox # Lint Yaml - name: Yaml Lint diff --git a/cypress/e2e/author.cy.js b/cypress/e2e/author.cy.js index e06bdd6..f124e66 100644 --- a/cypress/e2e/author.cy.js +++ b/cypress/e2e/author.cy.js @@ -1,6 +1,6 @@ describe('Author Search', () => { // see #14 - describe.only('glaser karin' , () => { + describe('glaser karin' , () => { beforeEach(() => { cy.visit({ url: '/Results', @@ -11,14 +11,11 @@ describe('Author Search', () => { }) }) - // Bei Author-Suche Autorenfeld boosten (gegenüber anderen Feldern, auch Titel) - it('should appear before child work', () => { + // erster Treffer von Autorin + it('first hit should be by the author', () => { cy.get('#result0') - .find('.media-type') - .contains(' Zeitschrift (gedruckt) ') - cy.get('#result1') - .find('.media-type') - .contains(' Band einer Zeitschrift/Zeitung ') + .find('.resultlist-data') + .contains('Karin Glaser') }) }) @@ -28,21 +25,19 @@ describe('Author Search', () => { url: '/Results', qs: { lookfor: '阎连科', - type: 'allFields' + type: 'Author' } }) }) - // (DP): 3 hits no child works as far as I can see - // PPN: 168000709 - it('first hit should be parent work', () => { - cy.get('[href*="168000709"]') - .should('exist') + // see #22 + it('CJK author search should return translations', () => { + cy.get('.record-list') + .contains('Yan, Lianke') }) }) describe('"Corte, Justine del"', () => { - // (DP): parent work not in top 20 beforeEach(() => { cy.visit({ url: '/Results', @@ -53,24 +48,14 @@ describe('Author Search', () => { }) }) - // TODO(DP): failing - // PPN: 521689139 - it('first hit should be parent work', () => { - cy.get('#result0') - .find('[href*="521689139"]') - .should('exist') - }) - - // TODO(DP): failing - it('first hit should not be child volume', () => { - cy.get('#result0') - .find('.media-type') - .should('not.contain', 'Band einer Zeitschrift/Zeitung') - .and('not.contain', 'Serial Volume') + it.only('strict search should only contain works by that author', () => { + cy.get('.resultlist-data') + .should('have.length.gte', 3) + .and('contain','Corte, Justine del') }) }) - describe('Andreas Gryphius' , () => { + describe.skip('Andreas Gryphius' , () => { beforeEach(() => { cy.visit({ url: '/Results', @@ -92,7 +77,7 @@ describe('Author Search', () => { }) }) - describe('oliver heaviside' , () => { + describe.skip('oliver heaviside' , () => { beforeEach(() => { cy.visit({ url: '/Results', diff --git a/cypress/e2e/multi-lang-phrase.cy.js b/cypress/e2e/multi-lang-phrase.cy.js index 173bc5b..430002e 100644 --- a/cypress/e2e/multi-lang-phrase.cy.js +++ b/cypress/e2e/multi-lang-phrase.cy.js @@ -18,7 +18,8 @@ describe('Foreign language phrase search', () => { }) - it('en subject query matches en and ar', () => { + // see #27 + it.skip('en subject query matches en and ar', () => { cy.visit({ url: '/Results', qs: { diff --git a/notes/Ranking_Stabikat.xlsx b/notes/Ranking_Stabikat.xlsx index d39e59a..0339de7 100644 Binary files a/notes/Ranking_Stabikat.xlsx and b/notes/Ranking_Stabikat.xlsx differ