【发布时间】:2018-09-21 07:44:38
【问题描述】:
我们正在使用 Detox 框架进行 IOS e2e 测试。 Detox 默认创建 e2e 文件夹并运行在其下创建的所有测试文件。
有什么方法可以在其他文件夹中创建测试文件并配置该路径并运行它?
【问题讨论】:
标签: react-native jestjs ios-ui-automation detox
我们正在使用 Detox 框架进行 IOS e2e 测试。 Detox 默认创建 e2e 文件夹并运行在其下创建的所有测试文件。
有什么方法可以在其他文件夹中创建测试文件并配置该路径并运行它?
【问题讨论】:
标签: react-native jestjs ios-ui-automation detox
【讨论】:
开玩笑的例子:
"detox": {
"test-runner": "jest",
"runner-config": "e2e/config.json" // default
"configurations": {
...
}
}
config.json 示例:
{
...
"roots": ["../src/..../e2e"],
"testMatch": [
"**/__tests__/**/*.[jt]s?(x)", "**/?(*.)+(spec|test).[jt]s?(x)" // default
]
}
【讨论】: