Update tests to use scoped anonymous structs.

Rather than defining the test types that are specific to a particular test
function outside of the scope of that test, define them inside the test
using anonymous structs.