Skip to content

Commit 4dcc945

Browse files
committed
Size should not be partial
1 parent fe53af1 commit 4dcc945

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/matchers/element/toHaveSize.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,15 @@ import type { RectReturn } from '@wdio/protocols'
1111

1212
export type Size = Pick<RectReturn, 'width' | 'height'>
1313

14-
async function condition(el: WebdriverIO.Element, size: Partial<Size>) {
14+
async function condition(el: WebdriverIO.Element, size: Size) {
1515
const actualSize = await el.getSize()
1616

1717
return compareObject(actualSize, size)
1818
}
1919

2020
export async function toHaveSize(
2121
received: WdioElementMaybePromise,
22-
expectedValue: Partial<Size>,
22+
expectedValue: Size,
2323
options: ExpectWebdriverIO.CommandOptions = DEFAULT_OPTIONS
2424
) {
2525
const matcherName = 'toHaveSize'

0 commit comments

Comments
 (0)