Skip to content

Commit

Permalink
Fix types for cy.dblclick and cy.rightclick (#5618)
Browse files Browse the repository at this point in the history
* ADDED: missing call signatures for right/dblclick

These two call signatures where missing for rightclick and dblclick: only the `rightclick(options?: Partial<ClickOptions>): Chainable<Subject> ` one was present.

See #5617

* FIXED: typo

* FIXED: dtslint errors
  • Loading branch information
warpdesign authored and jennifer-shehane committed Nov 7, 2019
1 parent 225bcd2 commit 9aeadbd
Showing 1 changed file with 48 additions and 1 deletion.
49 changes: 48 additions & 1 deletion cli/types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -620,13 +620,60 @@ declare namespace Cypress {
* @see https://on.cypress.io/dblclick
*/
dblclick(options?: Partial<ClickOptions>): Chainable<Subject>

/**
* Double-click a DOM element at specific corner / side.
*
* @param {String} position - The position where the click should be issued.
* The `center` position is the default position.
* @see https://on.cypress.io/dblclick
* @example
* cy.get('button').dblclick('topRight')
*/
dblclick(position: string, options?: Partial<ClickOptions>): Chainable<Subject>
/**
* Double-click a DOM element at specific coordinates
*
* @param {number} x The distance in pixels from the element’s left to issue the click.
* @param {number} y The distance in pixels from the element’s top to issue the click.
* @see https://on.cypress.io/dblclick
* @example
```
// The click below will be issued inside of the element
// (15px from the left and 40px from the top).
cy.get('button').dblclick(15, 40)
```
*/
dblclick(x: number, y: number, options?: Partial<ClickOptions>): Chainable<Subject>
/**
* Right-click a DOM element.
*
* @see https://on.cypress.io/rightclick
*/
rightclick(options?: Partial<ClickOptions>): Chainable<Subject>
/**
* Right-click a DOM element at specific corner / side.
*
* @param {String} position - The position where the click should be issued.
* The `center` position is the default position.
* @see https://on.cypress.io/click
* @example
* cy.get('button').rightclick('topRight')
*/
rightclick(position: string, options?: Partial<ClickOptions>): Chainable<Subject>
/**
* Right-click a DOM element at specific coordinates
*
* @param {number} x The distance in pixels from the element’s left to issue the click.
* @param {number} y The distance in pixels from the element’s top to issue the click.
* @see https://on.cypress.io/rightclick
* @example
```
// The click below will be issued inside of the element
// (15px from the left and 40px from the top).
cy.get('button').rightclick(15, 40)
```
*/
rightclick(x: number, y: number, options?: Partial<ClickOptions>): Chainable<Subject>

/**
* Set a debugger and log what the previous command yields.
Expand Down

4 comments on commit 9aeadbd

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 9aeadbd Nov 7, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Circle has built the linux x64 version of the Test Runner.

You can install this pre-release platform-specific build using instructions at https://on.cypress.io/installing-cypress#Install-pre-release-version.

You will need to use custom CYPRESS_INSTALL_BINARY url and install Cypress using an url instead of the version.

export CYPRESS_INSTALL_BINARY=https://cdn.cypress.io/beta/binary/3.6.1/linux-x64/circle-develop-9aeadbdfa20e1824dc0150b79182516ec97c6af8-187493/cypress.zip
npm install https://cdn.cypress.io/beta/npm/3.6.1/circle-develop-9aeadbdfa20e1824dc0150b79182516ec97c6af8-187454/cypress.tgz

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 9aeadbd Nov 7, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Circle has built the darwin x64 version of the Test Runner.

You can install this pre-release platform-specific build using instructions at https://on.cypress.io/installing-cypress#Install-pre-release-version.

You will need to use custom CYPRESS_INSTALL_BINARY url and install Cypress using an url instead of the version.

export CYPRESS_INSTALL_BINARY=https://cdn.cypress.io/beta/binary/3.6.1/darwin-x64/circle-develop-9aeadbdfa20e1824dc0150b79182516ec97c6af8-187501/cypress.zip
npm install https://cdn.cypress.io/beta/npm/3.6.1/circle-develop-9aeadbdfa20e1824dc0150b79182516ec97c6af8-187494/cypress.tgz

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 9aeadbd Nov 7, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AppVeyor has built the win32 ia32 version of the Test Runner.

You can install this pre-release platform-specific build using instructions at https://on.cypress.io/installing-cypress#Install-pre-release-version.

You will need to use custom CYPRESS_INSTALL_BINARY url and install Cypress using an url instead of the version.

set CYPRESS_INSTALL_BINARY=https://cdn.cypress.io/beta/binary/3.6.1/win32-ia32/appveyor-develop-9aeadbdfa20e1824dc0150b79182516ec97c6af8-28701217/cypress.zip
npm install https://cdn.cypress.io/beta/binary/3.6.1/win32-ia32/appveyor-develop-9aeadbdfa20e1824dc0150b79182516ec97c6af8-28701217/cypress.zip

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 9aeadbd Nov 7, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AppVeyor has built the win32 x64 version of the Test Runner.

You can install this pre-release platform-specific build using instructions at https://on.cypress.io/installing-cypress#Install-pre-release-version.

You will need to use custom CYPRESS_INSTALL_BINARY url and install Cypress using an url instead of the version.

set CYPRESS_INSTALL_BINARY=https://cdn.cypress.io/beta/binary/3.6.1/win32-x64/appveyor-develop-9aeadbdfa20e1824dc0150b79182516ec97c6af8-28701217/cypress.zip
npm install https://cdn.cypress.io/beta/binary/3.6.1/win32-x64/appveyor-develop-9aeadbdfa20e1824dc0150b79182516ec97c6af8-28701217/cypress.zip

Please sign in to comment.