Lines Matching refs:teststr
27 uint8_t teststr[] = { 0x40, 0x01, 0x93, 0x34 };
30 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
33 CU_ASSERT(pdu->used_size == sizeof(teststr) - 4);
43 uint8_t teststr[] = { 0x55, 0x69, 0x12, 0x34, 't', 'o', 'k', 'e', 'n' };
46 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
49 CU_ASSERT(pdu->used_size == sizeof(teststr) - 4);
54 CU_ASSERT(memcmp(pdu->token, teststr + 4, 5) == 0);
60 uint8_t teststr[] = { 0x53, 0x69, 0x12, 0x34, 't', 'o', 'k', 'e', 'n' };
63 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
70 uint8_t teststr[] = { 0x59, 0x69, 0x12, 0x34,
75 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
79 teststr[0] = 0x5f;
81 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
88 uint8_t teststr[] = { 0x55, 0x73, 0x12, 0x34, 't', 'o', 'k', 'e',
93 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
96 CU_ASSERT(pdu->used_size == sizeof(teststr) - 4);
101 CU_ASSERT(memcmp(pdu->token, teststr + 4, 5) == 0);
110 uint8_t teststr[] = { 0x55, 0x73, 0x12, 0x34, 't', 'o', 'k', 'e',
115 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
122 uint8_t teststr[] = { 0x55, 0x73, 0x12, 0x34, 't', 'o', 'k', 'e',
128 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
131 CU_ASSERT(pdu->used_size == sizeof(teststr) - 4);
136 CU_ASSERT(memcmp(pdu->token, teststr + 4, 5) == 0);
141 CU_ASSERT(memcmp(pdu->data, teststr + 13, 7) == 0);
147 uint8_t teststr[] = { 0x50, 0x73, 0x12, 0x34,
153 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
156 CU_ASSERT(pdu->used_size == sizeof(teststr) - 4);
165 CU_ASSERT(memcmp(pdu->data, teststr + 5, 7) == 0);
171 uint8_t teststr[] = { 0x70, 0x00, 0x12, 0x34, 0xff };
174 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
181 uint8_t teststr[] = { 0x53, 0x73, 0x12, 0x34, 't', 'o', 'k',
186 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
192 uint8_t teststr[] = { 0x60, 0x00, 0x12, 0x34 };
195 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
198 CU_ASSERT(pdu->used_size == sizeof(teststr) - 4);
208 uint8_t teststr[] = { 0x70, 0x00, 0x12, 0x34 };
211 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
214 CU_ASSERT(pdu->used_size == sizeof(teststr) - 4);
224 uint8_t teststr[] = { 0x70, 0x00, 0x12, 0x34,
229 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
236 uint8_t teststr[] = { 0x60, 0x00, 0x12, 0x34,
241 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
246 * To test Issue #199 which reads one byte past the end of teststr[]
254 uint8_t teststr[] = {
278 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
298 uint8_t teststr[] = { 0x5a, 0x0a, 0x5b, 0x5b };
300 testpdu = coap_pdu_init(0, 0, 0, sizeof(teststr));
303 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), testpdu);
316 uint8_t teststr[512] = { 0x40, 0x01, 0x93, 0x34 };
322 for (idx = 4; idx < sizeof(teststr) - 4; idx += 2) {
323 teststr[idx] = 0xd0; /* 1 byte option delta follows */
324 teststr[idx + 1] = 0xff; /* option delta 268 */
327 result = coap_pdu_parse(COAP_PROTO_UDP, teststr, sizeof(teststr), pdu);
337 uint8_t teststr[] = { 0x45, 0x01, 0x12, 0x34, 't', 'o', 'k', 'e', 'n' };
351 CU_ASSERT(memcmp(pdu->token - 4, teststr, sizeof(teststr)) == 0);
393 uint8_t teststr[] = { 0x60, 0x99, 0x12, 0x34, 0x3d, 0x05, 0x66, 0x61,
441 CU_ASSERT(memcmp(pdu->token - 4, teststr, sizeof(teststr)) == 0);
447 uint8_t teststr[] = { 0x68, 0x84, 0x12, 0x34, '1', '2', '3', '4',
482 CU_ASSERT(memcmp(pdu->token - 4, teststr, sizeof(teststr)) == 0);
488 uint8_t teststr[] = { 0x50, 0x02, 0x12, 0x34, 0xff, '1', '2', '3',
504 CU_ASSERT(memcmp(pdu->token - 4, teststr, sizeof(teststr)) == 0);
510 uint8_t teststr[] = { 0x40, 0x43, 0x12, 0x34 };
527 CU_ASSERT(memcmp(pdu->token - 4, teststr, sizeof(teststr)) == 0);
533 uint8_t teststr[] = { 0x42, 0x43, 0x12, 0x34, 0x00, 0x01, 0xff, 0x00 };
554 CU_ASSERT(memcmp(pdu->token - 4, teststr, sizeof(teststr)) == 0);
560 uint8_t teststr[] = { 0x60, 0x44, 0x12, 0x34, 0x48, 's', 'o', 'm',
605 CU_ASSERT(memcmp(pdu->token - 4, teststr, sizeof(teststr)) == 0);
611 uint8_t teststr[] = { 0x62, 0x44, 0x12, 0x34, 0x00, 0x00, 0x8d, 0xf2,
693 CU_ASSERT(memcmp(pdu->token - 4, teststr, sizeof(teststr)) == 0);
985 uint8_t teststr[] = { 0x62, 0x44, 0x12, 0x34, 0x00, 0x00, 0x8d, 0xf2,
1065 CU_ASSERT(memcmp(pdu->token - 4, teststr, sizeof(teststr)) == 0);