Skip to content

Commit 599610d

Browse files
committed
fix(doc_spec): make save shortcut OS specific
1 parent 18432a4 commit 599610d

1 file changed

Lines changed: 21 additions & 1 deletion

File tree

cypress/integration/04_document_spec.js

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,12 +45,32 @@ context('Document Operations', () => {
4545

4646
// TODO(DP): make this work on all OS by either adjusting the key sequence ctrl+s cmd+s …
4747
// or by using the file menu UI instead
48+
// see https://github.com/cypress-io/cypress/pull/15388/files#
4849
// see #414
50+
51+
// it('sets focus on search files filters if user presses Cmd + F', () => {
52+
// if (Cypress.platform === 'darwin') {
53+
// cy.get('.filter').type('{cmd}F')
54+
// cy.get('.filter').should('have.focus')
55+
// }
56+
// })
57+
58+
// it('sets focus on search files filter if user presses Ctrl + F', () => {
59+
// if (Cypress.platform !== 'darwin') {
60+
// cy.get('.filter').type('{ctrl}F')
61+
// cy.get('.filter').should('have.focus')
62+
// }
63+
// })
4964
it('should let users edit new document', () => {
5065
cy.get('[node-id$=untitled-1]')
5166
.dblclick()
52-
cy.get('.view-line')
67+
if( Cypress.platform === 'darwin') {
68+
cy.get('.view-line')
5369
.type('asdf{meta+s}')
70+
} else {
71+
cy.get('.view-line')
72+
.type('asdf{ctrl+s}')
73+
}
5474
})
5575
// see #414 workaround is to run this after editing and saving the document,
5676
// we should be able to rename before entering content

0 commit comments

Comments
 (0)