我写过语法:mock().expectNoCall("productionCode")
正如Cpputest.org页面所说。但编译器说 mocksupport类不支持这种类型的订单。
test_RFID_Drv.c:322:9: error: ‘class MockSupport’ has no member named ‘expectNoCall’mock().expectNoCall("HAL_AS393x_ReadRegisters");
怎么用?我必须在标题中包含一些文件吗? 目前我有那些嘲笑:
/*! \include <CppUTest/CommandLineTestRunner.h> */
#include <CppUTest/CommandLineTestRunner.h>
/*! \include <CppUTest/TestHarness.h> */
#include <CppUTest/TestHarness.h>
/*! \include <CppUTestExt/MockSupport.h> */
#include <CppUTestExt/MockSupport.h>
问题是我想忽略一个混凝土系统调用。我不想测试它。