1# Test the support for extension fields. 2 3Import("env") 4 5# We use the files from the alltypes test case 6incpath = env.Clone() 7incpath.Append(PROTOCPATH = '$BUILD/alltypes') 8incpath.Append(CPPPATH = '$BUILD/alltypes') 9 10incpath.NanopbProto(["extensions", "extensions.options"]) 11enc = incpath.Program(["encode_extensions.c", "extensions.pb.c", "$BUILD/alltypes/alltypes.pb$OBJSUFFIX", "$COMMON/pb_encode.o", "$COMMON/pb_common.o"]) 12dec = incpath.Program(["decode_extensions.c", "extensions.pb.c", "$BUILD/alltypes/alltypes.pb$OBJSUFFIX", "$COMMON/pb_decode.o", "$COMMON/pb_common.o"]) 13 14env.RunTest(enc) 15env.RunTest([dec, "encode_extensions.output"]) 16 17