Fix struct test

It wasn't testing what we wanted to test, since it was serializing the
data into JSON before comparing. Using DeepEqual directly on the
structs validates that they do have the expected types.