public void TestShuffle() { int[] values = new int[52]; for (int i = 0; i < 52; ++i) { values[i] = i; } RNG.Shuffle(values); int sum = 0; for (int i = 0; i < 52; ++i) { sum += values[i]; } Assert.Equal(288, Counter.BitsRead); // Has a low probability of failure Assert.Equal((51 * 52) / 2, sum); // Basic test to see if it's shuffled. }