Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
apache
Incubator Pegasus
提交
af174a4d
Incubator Pegasus
项目概览
apache
/
Incubator Pegasus
通知
9
Star
5
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Incubator Pegasus
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
af174a4d
编写于
8月 27, 2019
作者:
H
HuangWei
提交者:
Wu Tao
8月 27, 2019
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix: unit tests & travis.sh exit with err (#385)
上级
dea2bd9b
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
16 addition
and
14 deletion
+16
-14
scripts/travis.sh
scripts/travis.sh
+5
-3
src/base/test/main.cpp
src/base/test/main.cpp
+2
-2
src/geo/test/main.cpp
src/geo/test/main.cpp
+2
-2
src/redis_protocol/proxy_ut/redis_proxy_test.cpp
src/redis_protocol/proxy_ut/redis_proxy_test.cpp
+2
-2
src/server/test/main.cpp
src/server/test/main.cpp
+3
-3
src/test/function_test/main.cpp
src/test/function_test/main.cpp
+2
-2
未找到文件。
scripts/travis.sh
浏览文件 @
af174a4d
...
...
@@ -17,7 +17,9 @@ if [ "$modified" ]; then
fi
"
${
root
}
"
/run.sh build
-c
--skip_thirdparty
--disable_gperf
&&
./run.sh
test
--on_travis
if
[
$
?
]
;
then
echo
"travis failed with exit code
$
?
"
ret
=
$?
if
[
$
ret
]
;
then
echo
"travis failed with exit code
$
ret
"
fi
exit
$ret
src/base/test/main.cpp
浏览文件 @
af174a4d
...
...
@@ -8,6 +8,6 @@
GTEST_API_
int
main
(
int
argc
,
char
**
argv
)
{
testing
::
InitGoogleTest
(
&
argc
,
argv
);
int
ans
=
RUN_ALL_TESTS
();
dsn_exit
(
ans
);
int
ret
=
RUN_ALL_TESTS
();
dsn_exit
(
ret
);
}
src/geo/test/main.cpp
浏览文件 @
af174a4d
...
...
@@ -8,6 +8,6 @@
GTEST_API_
int
main
(
int
argc
,
char
**
argv
)
{
testing
::
InitGoogleTest
(
&
argc
,
argv
);
int
ans
=
RUN_ALL_TESTS
();
dsn_exit
(
ans
);
int
ret
=
RUN_ALL_TESTS
();
dsn_exit
(
ret
);
}
src/redis_protocol/proxy_ut/redis_proxy_test.cpp
浏览文件 @
af174a4d
...
...
@@ -602,6 +602,6 @@ GTEST_API_ int main(int argc, char **argv)
{
testing
::
InitGoogleTest
(
&
argc
,
argv
);
dsn_init
();
int
ans
=
RUN_ALL_TESTS
();
dsn_exit
(
ans
);
int
ret
=
RUN_ALL_TESTS
();
dsn_exit
(
ret
);
}
src/server/test/main.cpp
浏览文件 @
af174a4d
...
...
@@ -8,6 +8,7 @@
#include "server/pegasus_server_impl.h"
std
::
atomic_bool
gtest_done
{
false
};
std
::
atomic_int
gtest_ret
{
false
};
class
gtest_app
:
public
dsn
::
service_app
{
...
...
@@ -17,7 +18,7 @@ public:
dsn
::
error_code
start
(
const
std
::
vector
<
std
::
string
>
&
args
)
override
{
dsn
::
service_app
::
start
(
args
);
RUN_ALL_TESTS
();
gtest_ret
=
RUN_ALL_TESTS
();
gtest_done
=
true
;
return
dsn
::
ERR_OK
;
}
...
...
@@ -37,6 +38,5 @@ GTEST_API_ int main(int argc, char **argv)
while
(
!
gtest_done
)
{
std
::
this_thread
::
sleep_for
(
std
::
chrono
::
seconds
(
1
));
}
dsn_exit
(
0
);
dsn_exit
(
gtest_ret
);
}
src/test/function_test/main.cpp
浏览文件 @
af174a4d
...
...
@@ -43,6 +43,6 @@ GTEST_API_ int main(int argc, char **argv)
int
gargc
=
argc
-
2
;
testing
::
InitGoogleTest
(
&
gargc
,
argv
+
2
);
int
ans
=
RUN_ALL_TESTS
();
dsn_exit
(
ans
);
int
ret
=
RUN_ALL_TESTS
();
dsn_exit
(
ret
);
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录