Skip to content

Commit 89ceb7a

Browse files
jennifer-shehanebrian-mann
authored andcommitted
Remove incorrect typing for Cypress.Commands.overwrite - does not accept options (#5347)
* Remove incorrect typing for Cypress.Commands.overwrite - does not accept options * remove test that accepted options
1 parent abdf436 commit 89ceb7a

File tree

2 files changed

+0
-4
lines changed

2 files changed

+0
-4
lines changed

cli/types/index.d.ts

-1
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,6 @@ declare namespace Cypress {
292292
add(name: string, fn: (...args: any[]) => void): void
293293
add(name: string, options: CommandOptions, fn: (...args: any[]) => void): void
294294
overwrite(name: string, fn: (...args: any[]) => void): void
295-
overwrite(name: string, options: CommandOptions, fn: (...args: any[]) => void): void
296295
}
297296

298297
/**

cli/types/tests/cypress-tests.ts

-3
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,6 @@ namespace CypressCommandsTests {
6161
Cypress.Commands.overwrite('newCommand', () => {
6262
return
6363
})
64-
Cypress.Commands.overwrite('newCommand', { prevSubject: true }, () => {
65-
return
66-
})
6764
}
6865

6966
namespace CypressLogsTest {

0 commit comments

Comments
 (0)