diff --git a/types/cavy/cavy-tests.tsx b/types/cavy/cavy-tests.tsx index 5b7c9af0ee..b0d1ee98dd 100644 --- a/types/cavy/cavy-tests.tsx +++ b/types/cavy/cavy-tests.tsx @@ -54,7 +54,7 @@ class SampleComponent extends React.Component { {foo} - + {}}/> ); } @@ -78,6 +78,7 @@ function sampleSpec(spec: TestScope) { spec.findComponent('View'); // $ExpectType Promise> spec.press('View'); // $ExpectType Promise spec.fillIn('Input', 'hello world'); // $ExpectType Promise + spec.focus('Input'); // $ExpectType Promise spec.pause(1000); // $ExpectType Promise spec.exists('View'); // $ExpectType Promise spec.notExists('View.MissingSample'); // $ExpectType Promise diff --git a/types/cavy/index.d.ts b/types/cavy/index.d.ts index cbe829f72f..3023cb6373 100644 --- a/types/cavy/index.d.ts +++ b/types/cavy/index.d.ts @@ -1,4 +1,4 @@ -// Type definitions for cavy 3.1 +// Type definitions for cavy 3.2 // Project: https://github.com/pixielabs/cavy // Definitions by: Tyler Hoffman // Abigail McPhillips @@ -53,6 +53,7 @@ export class TestScope { beforeEach(fn: () => void): void; press(identifier: string): Promise; fillIn(identifier: string, str: string): Promise; + focus(identifier: string): Promise; pause(time: number): Promise; exists(identifier: string): Promise; notExists(identifier: string): Promise;