in reply to writing tests on modules

If I am returning a random array element what is an appropriate test for this type of thing?

You may want to check Test::RandomResults.