MOS Source Code
Loading...
Searching...
No Matches
oneof_size.cc
Go to the documentation of this file.
1
#include "oneof.pb.h"
2
#include "
unittests.h
"
3
4
extern
"C"
int
main
()
5
{
6
int
status = 0;
7
8
// Expected maximum encoded size:
9
// 1 byte for MyMessage.foo tag
10
// 1-5 bytes for MyMessage.foo submsg length
11
// 1 byte for SubMessage3.foo tag
12
// 5 bytes for SubMessage3.foo value
13
// 1 byte for SubMessage3.bar tag
14
// 5 bytes for SubMessage3.bar value
15
printf(
"Size: %d\n"
, (
int
)MyMessage_size);
16
TEST
(MyMessage_size == 18);
17
18
return
status;
19
}
main
int main()
Definition
oneof_size.cc:4
TEST
#define TEST(x)
Definition
test.h:3
unittests.h
libs
nanopb
nanopb
tests
regression
issue_494
oneof_size.cc
Generated on Sun Sep 1 2024 18:22:52 for MOS Source Code by
1.12.0