Added test for user defined type.

While I'm nitpicking, can you remove the space at the end of the line here.