Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
async fetchWDABundle () {
if (!this.derivedDataPath) {
return await bundleWDASim();
}
const wdaBundlePath = await fs.walkDir(this.derivedDataPath, true, (item) => item.endsWith('WebDriverAgentRunner-Runner.app'));
if (!wdaBundlePath) {
throw new Error(`Couldn't find the WDA bundle in the ${this.derivedDataPath}`);
}
return wdaBundlePath;
}