(
initialOptions: Config.InitialOptions,
filter?: Filter,
)
| 108 | |
| 109 | describe('getTestPaths', () => { |
| 110 | const getTestPaths = async ( |
| 111 | initialOptions: Config.InitialOptions, |
| 112 | filter?: Filter, |
| 113 | ) => { |
| 114 | const {searchSource, config} = await initSearchSource(initialOptions); |
| 115 | const allConfig = { |
| 116 | ...config, |
| 117 | ...initialOptions, |
| 118 | testPathPatterns: new TestPathPatterns([]), |
| 119 | }; |
| 120 | const {tests: paths} = await searchSource.getTestPaths( |
| 121 | allConfig, |
| 122 | allConfig, |
| 123 | null, |
| 124 | filter, |
| 125 | ); |
| 126 | return paths.map(({path: p}) => path.relative(rootDir, p)).sort(); |
| 127 | }; |
| 128 | |
| 129 | it('finds tests matching a pattern via testRegex', async () => { |
| 130 | const paths = await getTestPaths({ |
no test coverage detected