Merge pull request #392 from acozzette/fix-test-asserts

Fixed some test assertions in test-generated-code2.c
This commit is contained in:
Robert Edmonds 2019-10-18 21:15:21 -04:00 committed by GitHub
commit ff04761e39
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1683,7 +1683,7 @@ assert_required_default_values_are_default (Foo__DefaultRequiredValues *mess)
assert (mess->v_float == 2.5);
assert (mess->v_double == 4.5);
assert (strcmp (mess->v_string, "hi mom\n") == 0);
assert (mess->v_bytes.len = /* a */ 1
assert (mess->v_bytes.len == /* a */ 1
+ /* space */ 1
+ /* NUL */ 1
+ /* space */ 1
@ -1722,7 +1722,7 @@ assert_optional_default_values_are_default (Foo__DefaultOptionalValues *mess)
assert (mess->v_double == 4.5);
assert (strcmp (mess->v_string, "hi mom\n") == 0);
assert (!mess->has_v_bytes);
assert (mess->v_bytes.len = /* a */ 1
assert (mess->v_bytes.len == /* a */ 1
+ /* space */ 1
+ /* NUL */ 1
+ /* space */ 1