Initial import of libdpf.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
commit
e4e666f459
4563 changed files with 1690372 additions and 0 deletions
24
thirdparty/uint256_t/tests/testcases/equals.cpp
vendored
Normal file
24
thirdparty/uint256_t/tests/testcases/equals.cpp
vendored
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
#include <gtest/gtest.h>
|
||||
|
||||
#include "uint256_t.h"
|
||||
|
||||
TEST(Comparison, equals){
|
||||
EXPECT_EQ( (uint256_t(0xdeadbeefULL) == uint256_t(0xdeadbeefULL)), true);
|
||||
EXPECT_EQ(!(uint256_t(0xdeadbeefULL) == uint256_t(0xfee1baadULL)), true);
|
||||
}
|
||||
|
||||
TEST(External, equals){
|
||||
const bool t = true;
|
||||
const bool f = false;
|
||||
const uint8_t u8 = 0xaaULL;
|
||||
const uint16_t u16 = 0xaaaaULL;
|
||||
const uint32_t u32 = 0xaaaaaaaaULL;
|
||||
const uint64_t u64 = 0xaaaaaaaaaaaaaaaaULL;
|
||||
|
||||
EXPECT_EQ(t, uint256_t(t));
|
||||
EXPECT_EQ(f, uint256_t(f));
|
||||
EXPECT_EQ(u8, uint256_t(u8));
|
||||
EXPECT_EQ(u16, uint256_t(u16));
|
||||
EXPECT_EQ(u32, uint256_t(u32));
|
||||
EXPECT_EQ(u64, uint256_t(u64));
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue