标签: react-native jestjs enzyme
我怎样才能通过开玩笑来测试onPress并将我的按钮组件分解为其他组件内部的内容?
代码示例:
export default class PhoneVerificationScreen extends Component { render() { return ( <GradientButton onPress={this._checkNumber} /> ); } }
完整课程:https://pastebin.com/ujN3hF0h