Lines Matching defs:bytes
191 * @tc.desc: Interconversion between trace id and bytes array.
202 * @tc.steps: step3. convert trace id to bytes array.
204 * @tc.steps: step4. convert bytes array to trace id.
206 * @tc.steps: step5. convert invalid id to bytes array.
208 * @tc.steps: step6. convert invalid bytes array to id.
225 uint8_t bytes[ID_LEN + 1];
226 int len = initId.ToBytes(bytes, ID_LEN - 1);
228 len = initId.ToBytes(bytes, ID_LEN + 1);
230 len = initId.ToBytes(bytes, ID_LEN);
233 /* bytes to id */
234 HiTraceId bytesToId = HiTraceId(bytes, ID_LEN - 1);
236 bytesToId = HiTraceId(bytes, ID_LEN + 1);
238 bytesToId = HiTraceId(bytes, ID_LEN);
247 EXPECT_EQ(0, invalidId.ToBytes(bytes, ID_LEN));