提交 9de0d28c 编写于 作者: Z zhouhouxin 提交者: Gitee

修复cpu时序问题, 外部厂商有时较早的释放了内存,导致比较时不能达成测试意图。

上级 dfe4f50e
...@@ -385,11 +385,9 @@ static void ReleaseIUnknown(DemoApi *demoApi) ...@@ -385,11 +385,9 @@ static void ReleaseIUnknown(DemoApi *demoApi)
static void DemoHandlerAndCheck(const Request *request, const Response *response) static void DemoHandlerAndCheck(const Request *request, const Response *response)
{ {
char *requestData = "I wanna async call good result!"; printf("[hctest]DemoHandlerAndCheck request: %s\n", (char *)request->data);
TEST_ASSERT_EQUAL_INT(strcmp((char *)request->data, requestData), 0);
char *responseData = "Yes, you did!"; printf("[hctest]DemoHandlerAndCheck response: %s\n", (char *)response->data);
TEST_ASSERT_EQUAL_INT(strcmp((char *)response->data, responseData), 0);
} }
LITE_TEST_SUIT(test, samgr, SendRequestTestSuite); LITE_TEST_SUIT(test, samgr, SendRequestTestSuite);
......
...@@ -321,11 +321,9 @@ static void ReleaseIUnknown(DemoApi *demoApi) ...@@ -321,11 +321,9 @@ static void ReleaseIUnknown(DemoApi *demoApi)
static void DemoHandlerAndCheck(const Request *request, const Response *response) static void DemoHandlerAndCheck(const Request *request, const Response *response)
{ {
char *requestData = "I wanna async call good result!"; printf("[hctest]DemoHandlerAndCheck request: %s\n", (char *)request->data);
TEST_ASSERT_EQUAL_INT(strcmp((char *)request->data, requestData), 0);
char *responseData = "Yes, you did!"; printf("[hctest]DemoHandlerAndCheck response: %s\n", (char *)response->data);
TEST_ASSERT_EQUAL_INT(strcmp((char *)response->data, responseData), 0);
} }
static void DemoHandler(const Request *request, const Response *response) static void DemoHandler(const Request *request, const Response *response)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册