Skip to content

Commit ad70062

Browse files
committed
fixup! test: Add CSV import integration and unit tests
1 parent cb36a60 commit ad70062

1 file changed

Lines changed: 12 additions & 18 deletions

File tree

cypress/e2e/boardFeatures.js

Lines changed: 12 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -27,18 +27,15 @@ describe('Board', function() {
2727
url: '/ocs/v2.php/apps/deck/api/v1.0/boards',
2828
}).as('createBoardRequest')
2929

30-
// Expand "Add board" menu
31-
cy.contains('.app-navigation__list .app-navigation-entry', 'Add board')
32-
.find('button.icon-collapse').click({ force: true })
33-
34-
// Click "Create new board" sub-item
35-
cy.contains('ul.app-navigation-entry__children .app-navigation-entry', 'Create new board')
36-
.should('be.visible')
37-
.click({ force: true })
30+
// Expand "Add board" menu and click "Create new board"
31+
cy.get('#app-navigation-vue .app-navigation__list .app-navigation-entry')
32+
.contains('a', 'Add board').click({ force: true })
33+
cy.get('#app-navigation-vue .app-navigation-entry__children')
34+
.contains('a', 'Create new board').click({ force: true })
3835

3936
// Type the board title
40-
cy.get('.board-create form input[type=text]', { timeout: 10000 })
41-
.should('be.visible')
37+
cy.get('.board-create form input', { timeout: 10000 })
38+
.should('exist')
4239
.type(board, { force: true })
4340

4441
// Submit
@@ -272,14 +269,11 @@ describe('Board import', function() {
272269
})
273270

274271
it('Imports a board from JSON', function() {
275-
// Expand "Add board" menu
276-
cy.contains('.app-navigation__list .app-navigation-entry', 'Add board')
277-
.find('button.icon-collapse').click({ force: true })
278-
279-
// Click "Import from device" sub-item
280-
cy.contains('ul.app-navigation-entry__children .app-navigation-entry', 'Import from device')
281-
.should('be.visible')
282-
.click({ force: true })
272+
// Expand "Add board" menu and click "Import from device"
273+
cy.get('#app-navigation-vue .app-navigation__list .app-navigation-entry')
274+
.contains('a', 'Add board').click({ force: true })
275+
cy.get('#app-navigation-vue .app-navigation-entry__children')
276+
.contains('a', 'Import from device').click({ force: true })
283277

284278
// Upload a JSON file
285279
cy.get('#app-navigation-vue input[type="file"][accept*="json"]')

0 commit comments

Comments
 (0)