Lines Matching refs:ClassOfDevice
24 using bluetooth::hci::ClassOfDevice;
30 ClassOfDevice cod(test_bytes); in TEST()
42 ClassOfDevice cod; in TEST()
43 ClassOfDevice::FromString(test_class, cod); in TEST()
55 ClassOfDevice cod; in TEST()
56 size_t expected_result = ClassOfDevice::kLength; in TEST()
69 ClassOfDevice cod1; in TEST()
70 ClassOfDevice cod2; in TEST()
71 ClassOfDevice::FromString(test_class, cod1); in TEST()
80 ASSERT_FALSE(ClassOfDevice::IsValid("")); in TEST()
81 ASSERT_FALSE(ClassOfDevice::IsValid("000000")); in TEST()
82 ASSERT_FALSE(ClassOfDevice::IsValid("00-00-00")); in TEST()
83 ASSERT_FALSE(ClassOfDevice::IsValid("000-0-0")); in TEST()
84 ASSERT_TRUE(ClassOfDevice::IsValid("000-0-00")); in TEST()
85 ASSERT_TRUE(ClassOfDevice::IsValid("ABc-d-00")); in TEST()
86 ASSERT_TRUE(ClassOfDevice::IsValid("aBc-D-eF")); in TEST()
90 ClassOfDevice cod; in TEST()
92 ASSERT_TRUE(ClassOfDevice::FromString("000-0-00", cod)); in TEST()
93 const ClassOfDevice result0 = {{0x00, 0x00, 0x00}}; in TEST()
94 ASSERT_EQ(0, memcmp(cod.data(), result0.data(), ClassOfDevice::kLength)); in TEST()
96 ASSERT_TRUE(ClassOfDevice::FromString("ab2-1-4C", cod)); in TEST()
97 const ClassOfDevice result1 = {{0x4c, 0x21, 0xab}}; in TEST()
98 ASSERT_EQ(0, memcmp(cod.data(), result1.data(), ClassOfDevice::kLength)); in TEST()
102 auto cod = ClassOfDevice::FromUint32Legacy(0); in TEST()
107 cod = ClassOfDevice::FromUint32Legacy(0xab214c); in TEST()
112 ASSERT_FALSE(ClassOfDevice::FromUint32Legacy(0x1ab214c)); in TEST()