(
project: ProjectConfiguration,
file: {
names: string[];
extensions: string[];
},
)
| 85 | } |
| 86 | |
| 87 | async function findProjectFile( |
| 88 | project: ProjectConfiguration, |
| 89 | file: { |
| 90 | names: string[]; |
| 91 | extensions: string[]; |
| 92 | }, |
| 93 | ): Promise<string | undefined> { |
| 94 | // eslint-disable-next-line functional/no-loop-statements |
| 95 | for (const name of file.names) { |
| 96 | // eslint-disable-next-line functional/no-loop-statements |
| 97 | for (const ext of file.extensions) { |
| 98 | const filename = `./${project.root}/${name}.${ext}`; |
| 99 | if (await fileExists(path.join(process.cwd(), filename))) { |
| 100 | return filename; |
| 101 | } |
| 102 | } |
| 103 | } |
| 104 | return undefined; |
| 105 | } |
no test coverage detected