Freeze/flatten datastructures for better unittest analysis