Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
export async function loadFixture(browser: Browser, name: string) {
const fixtureContent = await fs.readFile(
path.join(__dirname, `./fixtures/${name}.html`),
{ encoding: 'utf8' }
);
await browser.url('about:blank');
await browser.execute(createFixture, fixtureContent);
await setViewportSize(1024, 768);
}