Check (de)serialize roundtrip in fate compiler tests

This commit is contained in:
Ulf Norell 2019-06-03 12:06:26 +02:00
parent a60d04d794
commit ed3ed6ded6

View File

@ -24,7 +24,8 @@ simple_compile_test_() ->
type_info := _} when Backend == aevm ->
?assertMatch(Code when is_binary(Code), ByteCode);
Code when Backend == fate, is_tuple(Code) ->
?assertMatch(#{}, aeb_fate_code:functions(Code));
Code1 = aeb_fate_code:deserialize(aeb_fate_code:serialize(Code)),
?assertMatch({X, X}, {Code1, Code});
ErrBin ->
io:format("\n~s", [ErrBin]),
error(ErrBin)