How to test for randomness?

I'd like to create a Random Number Generator from one of the analog inputs. What I'd like to do is take a sampling of that pin into an array of bits. Then I'd like to test that array for randomness. Not sure where to begin as far as the randomness test. Does anyone have any ideas how I can test for randomness?

I would start here:

That is: get the numbers into your PC and run the die hard or die harder test suites against them. These test suites are way better than anything you can produce on your own within any reasonable timeframe.

Some links:

I suspect you can find something useful at these two sites...

I'll be doing the same thing soon myself and I suspect that test for randomness on the Arduino itself will be tough (All though I'm not math strong so....?).

Rob (Rusew on this site) has also done an Arduino based random event generator an posted some info here but has tackled the testing externally using the diehard tests.

As my design will be running constantly my initial thoughts are to try and implement a bitstream test, although I haven't given the idea much thought.

Rob's post http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1241455197/