admin管理员组文章数量:1401438
I want to be able to specify a folder where my tests live so that Playwright doesn't try to run tests from all folders. Is there a way to tell Playwright to only run tests from a specific folder?
I want to be able to specify a folder where my tests live so that Playwright doesn't try to run tests from all folders. Is there a way to tell Playwright to only run tests from a specific folder?
Share Improve this question asked Jun 24, 2022 at 23:23 CullyCully 6,9756 gold badges42 silver badges63 bronze badges 01 Answer
Reset to default 3You can do this using the testDir config option. For example:
// playwright.config.ts
import { PlaywrightTestConfig } from '@playwright/test';
const config: PlaywrightTestConfig = {
testDir: './tests/playwright',
};
export default config;
It's also possible to do this by providing a folder when running playwright
from the mand line:
npx playwright test path/to/tests/playwright
本文标签: javascriptHow do you specify a test folderpath with PlaywrightStack Overflow
版权声明:本文标题:javascript - How do you specify a test folderpath with Playwright? - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744246817a2597056.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论