Skip to content

Commit 38b01b7

Browse files
committed
refactor: derive configuration options type for Testing Library types
1 parent 9663c5e commit 38b01b7

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

lib/typedefs.ts

+5-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import {
22
Matcher,
33
ByRoleOptions as TestingLibraryByRoleOptions,
4+
Config as TestingLibraryConfig,
45
MatcherOptions as TestingLibraryMatcherOptions,
56
SelectorMatcherOptions as TestingLibrarySelectorMatcherOptions,
67
waitForOptions,
@@ -189,7 +190,7 @@ export interface Queries extends QueryMethods {
189190
getNodeText(el: Element): Promise<string>
190191
}
191192

192-
export interface ConfigurationOptions {
193-
testIdAttribute: string
194-
asyncUtilTimeout: number
195-
}
193+
export type ConfigurationOptions = Pick<
194+
TestingLibraryConfig,
195+
'testIdAttribute' | 'asyncUtilTimeout'
196+
>

0 commit comments

Comments
 (0)