Skip to content

Commit

Permalink
feat: finished integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
nicoalee committed Sep 18, 2024
1 parent 7e07a12 commit a4b693f
Show file tree
Hide file tree
Showing 6 changed files with 1,392 additions and 581 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -198,14 +198,14 @@ describe('ImportStudiesDialog', () => {
});

it('should set the source and show the input', () => {
cy.get('input[role="combobox"').click();
cy.get('input[role="combobox"]').click();
cy.contains('li', 'Scopus').click();
cy.get('textarea').should('be.visible');
cy.contains(/Input is empty/).should('be.visible');
});

it('should set the sources and enable the next button', () => {
cy.get('input[role="combobox"').click();
cy.get('input[role="combobox"]').click();
cy.contains('li', 'Scopus').click();
cy.get('textarea[placeholder="paste in valid endnote, bibtex, or RIS syntax"]')
.click()
Expand All @@ -220,7 +220,7 @@ describe('ImportStudiesDialog', () => {
});

it('should show an error message', () => {
cy.get('input[role="combobox"').click();
cy.get('input[role="combobox"]').click();
cy.contains('li', 'Scopus').click();
cy.get('textarea[placeholder="paste in valid endnote, bibtex, or RIS syntax"]').type(
'INVALID FORMAT'
Expand All @@ -229,7 +229,7 @@ describe('ImportStudiesDialog', () => {
});

it('should import studies', () => {
cy.get('input[role="combobox"').click();
cy.get('input[role="combobox"]').click();
cy.contains('li', 'Scopus').click();
cy.get('textarea[placeholder="paste in valid endnote, bibtex, or RIS syntax"]')
.click()
Expand All @@ -249,7 +249,7 @@ describe('ImportStudiesDialog', () => {
});

it('should upload a onenote (ENW) file', () => {
cy.get('input[role="combobox"').click();
cy.get('input[role="combobox"]').click();
cy.contains('li', 'Scopus').click();
cy.get('label[role="button"]').selectFile(
'cypress/fixtures/standardFiles/onenoteStudies.txt'
Expand Down
Loading

0 comments on commit a4b693f

Please sign in to comment.