Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
8060fdde
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看板
提交
8060fdde
编写于
6月 02, 2021
作者:
O
openharmony_ci
提交者:
Gitee
6月 02, 2021
浏览文件
操作
浏览文件
下载
差异文件
!241 【轻鸿蒙内核子系统集成测试】修改futex_posix模块代码不稳定的用例:PthreadCondTest.cpp#
Merge pull request !241 from limeng/kernel_lite_2021060201
上级
92cb2fa0
fbcff12e
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
11 addition
and
11 deletion
+11
-11
kernel_lite/futex_posix/src/PthreadCondTest.cpp
kernel_lite/futex_posix/src/PthreadCondTest.cpp
+11
-11
未找到文件。
kernel_lite/futex_posix/src/PthreadCondTest.cpp
浏览文件 @
8060fdde
...
...
@@ -144,8 +144,8 @@ HWTEST_F(FutexTest, testPthreadCondSignalBefore, Function | MediumTest | Level3)
ASSERT_EQ
(
pthread_create
(
&
tid
[
1
],
nullptr
,
ThreadPthreadCondSignalBefore2
,
nullptr
),
0
)
<<
"> return errno"
;
Msleep
(
100
);
pthread_
cancel
(
tid
[
0
]
);
pthread_
cancel
(
tid
[
1
]
);
pthread_
join
(
tid
[
0
],
nullptr
);
pthread_
join
(
tid
[
1
],
nullptr
);
EXPECT_EQ
(
pthread_cond_destroy
(
&
g_cond1
),
0
);
EXPECT_EQ
(
pthread_mutex_destroy
(
&
g_mtx1
),
0
);
EXPECT_EQ
(
CheckStep
(
5
),
(
uint64_t
)
0x12345
);
...
...
@@ -189,8 +189,8 @@ HWTEST_F(FutexTest, testPthreadCondSignalAfter, Function | MediumTest | Level3)
ASSERT_EQ
(
pthread_create
(
&
tid
[
1
],
nullptr
,
ThreadTestCondSignalWaitAfter2
,
nullptr
),
0
)
<<
"> return errno"
;
Msleep
(
100
);
pthread_
cancel
(
tid
[
0
]
);
pthread_
cancel
(
tid
[
1
]
);
pthread_
join
(
tid
[
0
],
nullptr
);
pthread_
join
(
tid
[
1
],
nullptr
);
EXPECT_EQ
(
pthread_cond_destroy
(
&
g_cond2
),
0
);
EXPECT_EQ
(
pthread_mutex_destroy
(
&
g_mtx2
),
0
);
EXPECT_EQ
(
CheckStep
(
4
),
(
uint64_t
)
0x1234
);
...
...
@@ -237,9 +237,9 @@ HWTEST_F(FutexTest, testPthreadCondBroadcast, Function | MediumTest | Level3)
ASSERT_EQ
(
pthread_create
(
&
tid
[
2
],
nullptr
,
ThreadPthreadCondBroadcast2
,
(
void
*
)
&
testInt
),
0
)
<<
"> return errno"
;
Msleep
(
100
);
pthread_
cancel
(
tid
[
0
]
);
pthread_
cancel
(
tid
[
1
]
);
pthread_
cancel
(
tid
[
2
]
);
pthread_
join
(
tid
[
0
],
nullptr
);
pthread_
join
(
tid
[
1
],
nullptr
);
pthread_
join
(
tid
[
2
],
nullptr
);
EXPECT_EQ
(
pthread_cond_destroy
(
&
g_cond3
),
0
);
EXPECT_EQ
(
pthread_mutex_destroy
(
&
g_mtx3
),
0
);
EXPECT_EQ
(
testInt
,
12
);
...
...
@@ -292,8 +292,8 @@ HWTEST_F(FutexTest, testPthreadCondTimedwait, Function | MediumTest | Level3)
ASSERT_EQ
(
pthread_create
(
&
tid2
,
nullptr
,
ThreadPthreadCondTimedwait2
,
nullptr
),
0
)
<<
"> return errno"
;
Msleep
(
100
);
pthread_
cancel
(
tid1
);
pthread_
cancel
(
tid2
);
pthread_
join
(
tid1
,
nullptr
);
pthread_
join
(
tid2
,
nullptr
);
EXPECT_EQ
(
pthread_cond_destroy
(
&
g_cond4
),
0
);
EXPECT_EQ
(
pthread_mutex_destroy
(
&
g_mtx4
),
0
);
EXPECT_EQ
(
CheckStep
(
4
),
(
uint64_t
)
0x1234
);
...
...
@@ -335,7 +335,7 @@ HWTEST_F(FutexTest, testPthreadCondTimedwaitOut, Function | MediumTest | Level3)
ASSERT_EQ
(
pthread_create
(
&
tid
,
nullptr
,
ThreadPthreadCondTimedwaitOut
,
nullptr
),
0
)
<<
"> return errno"
;
Msleep
(
200
);
pthread_
cancel
(
tid
);
pthread_
join
(
tid
,
nullptr
);
EXPECT_EQ
(
pthread_cond_destroy
(
&
g_cond5
),
0
);
EXPECT_EQ
(
pthread_mutex_destroy
(
&
g_mtx5
),
0
);
EXPECT_EQ
(
CheckStep
(
3
),
(
uint64_t
)
0x123
);
...
...
@@ -373,7 +373,7 @@ HWTEST_F(FutexTest, testPthreadCondTimedwaitEinval, Function | MediumTest | Leve
ASSERT_EQ
(
pthread_create
(
&
tid
,
nullptr
,
ThreadPthreadCondTimedwaitEinval
,
nullptr
),
0
)
<<
"> return errno"
;
Msleep
(
200
);
pthread_
cancel
(
tid
);
pthread_
join
(
tid
,
nullptr
);
EXPECT_EQ
(
pthread_cond_destroy
(
&
g_cond6
),
0
);
EXPECT_EQ
(
pthread_mutex_destroy
(
&
g_mtx6
),
0
);
EXPECT_EQ
(
CheckStep
(
3
),
(
uint64_t
)
0x123
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录