pidl: fixed unit tests for trailer alignment
[ira/wip.git] / pidl / tests / samba-ndr.pl
index cdfe0514f1fd067e1d40d8e53bfc17e9aa7f2875..e2578178099f21ca73ba73705e9d5b6707508ff2 100755 (executable)
@@ -223,6 +223,7 @@ $generator->ParseStructPush({
                        ELEMENTS => [ ]}, "ndr", "x");
 is($generator->{res}, "if (ndr_flags & NDR_SCALARS) {
        NDR_CHECK(ndr_push_align(ndr, 4));
+       NDR_CHECK(ndr_push_trailer_align(ndr, 4));
 }
 if (ndr_flags & NDR_BUFFERS) {
 }
@@ -245,9 +246,10 @@ $generator->ParseStructPush({
                        SURROUNDING_ELEMENT => $e,
                        ELEMENTS => [ $e ]}, "ndr", "x");
 is($generator->{res}, "if (ndr_flags & NDR_SCALARS) {
-       NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_string_array_size(ndr, x->el1)));
+       NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_string_array_size(ndr, x->el1)));
        NDR_CHECK(ndr_push_align(ndr, 4));
        NDR_CHECK(ndr_push_mytype(ndr, NDR_SCALARS, &x->el1));
+       NDR_CHECK(ndr_push_trailer_align(ndr, 4));
 }
 if (ndr_flags & NDR_BUFFERS) {
 }