Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
a995fd4d
X
Xts Acts
项目概览
OpenHarmony
/
Xts Acts
1 年多 前同步成功
通知
9
Star
22
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
X
Xts Acts
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
a995fd4d
编写于
10月 18, 2021
作者:
W
wkejing
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fixed 218fcef from
https://gitee.com/w30013702/xts_acts/pulls/909
wip部分失败用例修改 Signed-off-by:
N
wkejing
<
wkejing9687@163.com
>
上级
43f477a7
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
13 addition
and
40 deletion
+13
-40
communication_lite/lwip_hal/src/lwip_func_test.c
communication_lite/lwip_hal/src/lwip_func_test.c
+13
-40
未找到文件。
communication_lite/lwip_hal/src/lwip_func_test.c
浏览文件 @
a995fd4d
...
...
@@ -555,6 +555,10 @@ LITE_TEST_CASE(LwipFuncTestSuite, testTcp, Function | MediumTest | Level2)
}
TEST_ASSERT_EQUAL_INT
(
1
,
g_clientResult
);
TEST_ASSERT_EQUAL_INT
(
1
,
g_serverResult
);
osDelay
(
ONE_SECOND
);
g_serverWait
=
1
;
g_clientWait
=
1
;
}
/**
...
...
@@ -646,50 +650,19 @@ LITE_TEST_CASE(LwipFuncTestSuite, testSelectTimeout, Function | MediumTest | Lev
}
/**
* @tc.number : SUB_COMMUNICATION_LWIP_SDK_0
6
00
* @tc.name : test s
elect with multi clients
* @tc.number : SUB_COMMUNICATION_LWIP_SDK_0
5
00
* @tc.name : test s
ocket
* @tc.desc : [C- SOFTWARE -0200]
*/
LITE_TEST_CASE
(
LwipFuncTestSuite
,
testS
electMultiClients
,
Function
|
MediumTest
|
Level2
)
LITE_TEST_CASE
(
LwipFuncTestSuite
,
testS
ocket
,
Function
|
MediumTest
|
Level2
)
{
osThreadAttr_t
tSelect
;
tSelect
.
name
=
"SelectServerTask"
;
tSelect
.
attr_bits
=
0U
;
tSelect
.
cb_mem
=
NULL
;
tSelect
.
cb_size
=
0U
;
tSelect
.
stack_mem
=
NULL
;
tSelect
.
stack_size
=
DEF_TASK_STACK
;
tSelect
.
priority
=
DEF_TASK_PRIORITY
;
g_selectTimeout
=
5
;
osThreadId_t
serverTaskId
=
osThreadNew
((
osThreadFunc_t
)
SelectServerTask
,
NULL
,
&
tSelect
);
TEST_ASSERT_NOT_NULL
(
serverTaskId
);
osDelay
(
ONE_SECOND
);
if
(
serverTaskId
==
NULL
)
{
printf
(
"create select server task fail!
\n
"
);
}
else
{
osThreadAttr_t
tClient
[
2
];
osThreadId_t
clientTaskId
;
char
taskName
[
2
][
8
]
=
{
"client1"
,
"client2"
};
for
(
int
i
=
0
;
i
<
2
;
i
++
)
{
tClient
[
i
].
name
=
taskName
[
i
];
tClient
[
i
].
attr_bits
=
0U
;
tClient
[
i
].
cb_mem
=
NULL
;
tClient
[
i
].
cb_size
=
0U
;
tClient
[
i
].
stack_mem
=
NULL
;
tClient
[
i
].
stack_size
=
DEF_TASK_STACK
;
tClient
[
i
].
priority
=
DEF_TASK_PRIORITY
;
clientTaskId
=
osThreadNew
((
osThreadFunc_t
)
CommTcpClientTask
,
NULL
,
&
tClient
[
i
]);
TEST_ASSERT_NOT_NULL
(
clientTaskId
);
}
int
fdFail
=
-
1
;
int
fdSuccess
=
-
1
;
g_selectFlag
=
1
;
while
(
g_selectFlag
)
{
osDelay
(
ONE_SECOND
);
printf
(
"wait select server finish...
\n
"
);
}
TEST_ASSERT_EQUAL_INT
(
0
,
g_selectResult
);
}
fdFail
=
socket
(
0
,
0
,
0
);
TEST_ASSERT_EQUAL_INT
(
LWIP_TEST_FAIL
,
fdFail
);
fdSuccess
=
socket
(
AF_INET
,
SOCK_STREAM
,
0
);
TEST_ASSERT_NOT_EQUAL
(
LWIP_TEST_FAIL
,
fdSuccess
);
}
/**
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录