A run test is defined as a maximal sequence of consecutive bits of either all ones or all zeros that is part of the 20,000 bits sample stream. The incidences of runs (for both consecutive zeros and consecutive ones) of all lengths (>=1) in the sample stream should be counted and stored.

The test is passed if the runs that occur (of lengths 1 through 6) are each within the corresponding interval specified in the table below. This must hold for both the zeros and ones. (ie. all 12 counts must lie in the specified interval). For the purpose of this test, runs of greater than 6 are considered to be of length 6.

Length of RunRequired Interval
12,315 - 2,685
21,114 - 1,386
3527 - 723
4240 - 384
5103-209
6+103-209