执行“单击”时出错-在坐标处

时间:2018-12-28 12:30:39

标签: react-native mocha jestjs detox

我正在对本机Android版本0.57进行排毒测试。我收到此错误。

错误是:

  

错误:错误:执行“单击”时出错-在坐标处:720,   1485,精度:视图'(具有标记值:is是16、16'   “ create_team_button”,并且视图具有有效的可见性= VISIBLE)'

代码为

it('should create team', async () => {
    await waitFor(element(by.id('create_team'))).toBeVisible().withTimeout(2000);
    await element(by.id('create_team')).typeText('mobile offize');
    await waitFor(element(by.id('create_team_button'))).toBeVisible().withTimeout(2000);
    await element(by.id('create_team_button')).tap();
  });

渲染功能是

render() {
    return (
       <View>
            <Button
                testID={'create_team_button'}
                rounded title={I18n.t("NEXT")}
                buttonStyle={styles.button}
                disabled ={!(this.state.teamName.length >0)}
                onPress={this.onCreateTeamButtonPressedDebounced} />
       </View>

F enter image description here空错误图片

0 个答案:

没有答案