Added test for randomness