blob: c50ddee70e77d948f1e0dc1e1ed59b85db1e197f [file] [log] [blame]
Anthony F. Molinaroe49a44a2011-06-18 06:04:01 +00001-module(test_thrift_1151).
2
3-include("thrift1151_types.hrl").
4
5-export([t/0, t1/0]).
6
7t() ->
8 S1 = #structC{x=#structB{x=1}},
9 {ok, Transport} = thrift_memory_buffer:new(),
10 {ok, Protocol} = thrift_binary_protocol:new(Transport),
11 thrift_protocol:write(Protocol,
12 {{struct, element(2, thrift1151_types:struct_info('structC'))}, S1}).
13
14t1() ->
15 S2 = #structC{x=#structA{x="1"}},
16 {ok, Transport} = thrift_memory_buffer:new(),
17 {ok, Protocol} = thrift_binary_protocol:new(Transport),
18 thrift_protocol:write(Protocol,
19 {{struct, element(2, thrift1151_types:struct_info('structC'))}, S2}).