added a test for a sampler in a struct passed to a function

This test passes on desktops and iOS, but fails on my Nexus 4.