fix use EXPECT_EXIT
Some checks failed
rpcrypto-build / build (Release, hisiv510.toolchain.cmake) (push) Successful in 54s
rpcrypto-build / build (Release, himix200.toolchain.cmake) (push) Successful in 1m5s
rpcrypto-build / build (Debug, himix200.toolchain.cmake) (push) Successful in 58s
rpcrypto-build / build (Debug, hisiv510.toolchain.cmake) (push) Successful in 47s
linux-x64-gcc / linux-gcc (push) Failing after 1m4s
linux-hisiv500-gcc / linux-gcc-hisiv500 (push) Successful in 1m18s
linux-mips64-gcc / linux-gcc-mips64el (push) Failing after 1m23s
Some checks failed
rpcrypto-build / build (Release, hisiv510.toolchain.cmake) (push) Successful in 54s
rpcrypto-build / build (Release, himix200.toolchain.cmake) (push) Successful in 1m5s
rpcrypto-build / build (Debug, himix200.toolchain.cmake) (push) Successful in 58s
rpcrypto-build / build (Debug, hisiv510.toolchain.cmake) (push) Successful in 47s
linux-x64-gcc / linux-gcc (push) Failing after 1m4s
linux-hisiv500-gcc / linux-gcc-hisiv500 (push) Successful in 1m18s
linux-mips64-gcc / linux-gcc-mips64el (push) Failing after 1m23s
This commit is contained in:
parent
3ecb4f508c
commit
7fd4f98db8
@ -1,3 +1,4 @@
|
|||||||
|
#include "gtest/gtest.h"
|
||||||
#include <gtest/gtest.h>
|
#include <gtest/gtest.h>
|
||||||
#include <ulib/concorrency/countdown_latch.h>
|
#include <ulib/concorrency/countdown_latch.h>
|
||||||
#include <pthread.h>
|
#include <pthread.h>
|
||||||
@ -52,4 +53,5 @@ TEST(CoundownLatch, Assert)
|
|||||||
// NOTE https://github.com/google/googletest/blob/main/docs/advanced.md#death-tests-and-threads
|
// NOTE https://github.com/google/googletest/blob/main/docs/advanced.md#death-tests-and-threads
|
||||||
GTEST_FLAG_SET(death_test_style, "threadsafe");
|
GTEST_FLAG_SET(death_test_style, "threadsafe");
|
||||||
EXPECT_DEATH(latch.CountDown(), ".*failed.*");
|
EXPECT_DEATH(latch.CountDown(), ".*failed.*");
|
||||||
|
EXPECT_EXIT(latch.CountDown(), ::testing::KilledBySignal(SIGABRT), "");
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user