单元测试:如何对componentDidUpdate进行单元测试?

时间:2019-11-06 16:34:53

标签: unit-testing mocha enzyme chai

我想对使用Mocha,Chia和酶的componentDidUpdate进行单元测试。我阅读了文档,但是componentDidUpdate没有任何显示。

  componentDidUpdate() {
        if (this.props.statusMessage.messageType === SUCCESSFUL_REQUEST_CLASS) {
            this.props.reset('futureChanges');
            this.props.resetFutureAgentTable();
            this.props.removeFutureTemplate();
        }
    }

0 个答案:

没有答案