assert toggle (#1377)

* assert toggle

* Update Assert.h
This commit is contained in:
ManDude
2022-05-29 00:27:58 +01:00
committed by GitHub
parent c1faeac042
commit 9449078a9b
4 changed files with 20 additions and 3 deletions
+4 -1
View File
@@ -16,6 +16,7 @@
#include "common/util/CopyOnWrite.h"
#include "common/util/SmallVector.h"
#include "common/util/crc32.h"
#include "common/util/Assert.h"
TEST(CommonUtil, CpuInfo) {
setup_cpu_info();
@@ -393,9 +394,11 @@ TEST(SmallVector, Construction) {
EXPECT_FALSE(one.empty());
}
#ifndef NO_ASSERT
TEST(Assert, Death) {
EXPECT_DEATH(private_assert_failed("foo", "bar", 12, "aaa"), "");
}
#endif
uint32_t crc_reference(const u8* data, size_t size) {
u32 crc = 0xffffffff;
@@ -419,4 +422,4 @@ TEST(CRC32, Reference) {
}
} // namespace test
} // namespace cu
} // namespace cu