【发布时间】:2018-07-31 10:31:40
【问题描述】:
如果我无法在运行前通过 In-App Developer Menu 启用远程 JS 调试(即未及时键入 command + D 并单击“启用远程 JS 调试”),则以下测试失败:
describe('Login form tests', () => {
beforeEach(async () => {
await device.reloadReactNative();
});
it('logins in user', async (done) => {
// typeText method doesn't work because of https://github.com/wix/detox/issues/92
await element(by.id('login_email')).replaceText('email@email.com');
await element(by.id('login_password')).replaceText('fakepassword');
// $FlowFixMe
await element(by.id('login_button')).tap();
done();
});
});
我在 package.json 中使用与文档建议相同的配置,但 -configuration Debug 在应用程序和反应本机重新加载时不会启用调试器。有没有默认启用调试器?
【问题讨论】:
-
我得到了完全相同的行为。你有想过这个吗?
标签: react-native detox