Lines Matching refs:WRITES

42 #define WRITES(x, y) \  macro
80 TEST(WRITES(pb_encode_varint(&s, 0), "\0")); in main()
81 TEST(WRITES(pb_encode_varint(&s, 1), "\1")); in main()
82 TEST(WRITES(pb_encode_varint(&s, 0x7F), "\x7F")); in main()
83 TEST(WRITES(pb_encode_varint(&s, 0x80), "\x80\x01")); in main()
84 TEST(WRITES(pb_encode_varint(&s, UINT32_MAX), "\xFF\xFF\xFF\xFF\x0F")); in main()
85 TEST(WRITES(pb_encode_varint(&s, UINT64_MAX), "\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x01")); in main()
93 TEST(WRITES(pb_encode_tag(&s, PB_WT_STRING, 5), "\x2A")); in main()
94 TEST(WRITES(pb_encode_tag(&s, PB_WT_VARINT, 99), "\x98\x06")); in main()
103 TEST(WRITES(pb_encode_tag_for_field(&s, &field), "\x50")); in main()
106 TEST(WRITES(pb_encode_tag_for_field(&s, &field), "\x51")); in main()
109 TEST(WRITES(pb_encode_tag_for_field(&s, &field), "\x52")); in main()
112 TEST(WRITES(pb_encode_tag_for_field(&s, &field), "\x55")); in main()
120 TEST(WRITES(pb_encode_string(&s, (const uint8_t*)"abcd", 4), "\x04""abcd")); in main()
121 TEST(WRITES(pb_encode_string(&s, (const uint8_t*)"abcd\x00", 5), "\x05""abcd\x00")); in main()
122 TEST(WRITES(pb_encode_string(&s, (const uint8_t*)"", 0), "\x00")); in main()
136 TEST(WRITES(pb_enc_varint(&s, &field, &value), "\x01")); in main()
139 TEST(WRITES(pb_enc_svarint(&s, &field, &max), "\xfe\xff\xff\xff\x0f")); in main()
140 TEST(WRITES(pb_enc_svarint(&s, &field, &min), "\xff\xff\xff\xff\x0f")); in main()
143 TEST(WRITES(pb_enc_svarint(&s, &field, &lmax), "\xFE\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x01")); in main()
144 TEST(WRITES(pb_enc_svarint(&s, &field, &lmin), "\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x01")); in main()
155 TEST(WRITES(pb_enc_fixed32(&s, NULL, &fvalue), "\x00\x00\x00\x00")) in main()
157 TEST(WRITES(pb_enc_fixed32(&s, NULL, &fvalue), "\x00\x00\xc6\x42")) in main()
159 TEST(WRITES(pb_enc_fixed32(&s, NULL, &fvalue), "\x4e\x61\x3c\xcb")) in main()
163 TEST(WRITES(pb_enc_fixed64(&s, NULL, &dvalue), "\x00\x00\x00\x00\x00\x00\x00\x00")) in main()
165 TEST(WRITES(pb_enc_fixed64(&s, NULL, &dvalue), "\x00\x00\x00\x00\x00\xc0\x58\x40")) in main()
167 TEST(WRITES(pb_enc_fixed64(&s, NULL, &dvalue), "\x00\x00\x00\xc0\x29\x8c\x67\xc1")) in main()
176 TEST(WRITES(pb_enc_bytes(&s, &BytesMessage_fields[0], &value), "\x05xyzzy")) in main()
178 TEST(WRITES(pb_enc_bytes(&s, &BytesMessage_fields[0], &value), "\x00")) in main()
187 TEST(WRITES(pb_enc_string(&s, &StringMessage_fields[0], &value), "\x05xyzzy")) in main()
189 TEST(WRITES(pb_enc_string(&s, &StringMessage_fields[0], &value), "\x00")) in main()
191 TEST(WRITES(pb_enc_string(&s, &StringMessage_fields[0], &value), "\x0Axxxxxxxxxx")) in main()
201 TEST(WRITES(pb_encode(&s, IntegerArray_fields, &msg), "\x0A\x05\x01\x02\x03\x04\x05")) in main()
204 TEST(WRITES(pb_encode(&s, IntegerArray_fields, &msg), "")) in main()
217 TEST(WRITES(pb_encode(&s, FloatArray_fields, &msg), in main()
221 TEST(WRITES(pb_encode(&s, FloatArray_fields, &msg), "")) in main()
249 TEST(WRITES(pb_encode(&s, CallbackArray_fields, &msg), "\x08\x55")) in main()
258 TEST(WRITES(pb_encode(&s, IntegerContainer_fields, &msg), in main()
268 TEST(WRITES(pb_encode(&s, BytesMessage_fields, &msg), in main()
282 TEST(WRITES(pb_encode_delimited(&s, IntegerContainer_fields, &msg), in main()
306 TEST(WRITES(pb_encode(&s, CallbackContainer_fields, &msg), "\x0A\x02\x08\x55")) in main()
307 TEST(WRITES(pb_encode(&s, CallbackContainerContainer_fields, &msg2), in main()
345 TEST(WRITES(pb_encode(&s, StringPointerContainer_fields, &msg), "\x0a\x00")) in main()
348 TEST(WRITES(pb_encode(&s, StringPointerContainer_fields, &msg), "\x0a\x01Z")) in main()