(or are shodo-thugs put in a pit to fight it out Peter?).
How did you know about that? Usually our gradings are very secret, hidden, underground things where we have to fight to the death and then eat the heart of our defeated Uke to appease the Aiki Warrior Gods.
Seriously though, for Dan tests there is a part where we engage in all the levels of tanto randori from low to high resistance. We usually do a max of 4 bouts at 2 minutes each being both Tori (Toshu) and Uke (Tanto).
In our case all tests have a set syllabus and primarily takes the form of a demonstration of techniques as well as other Aikido movement principles. Shodan is where the randori starts in addition to a demonstration element as an official requirement.
In our dojo I have added some personal randori requirements to the Kyuy syllabus since most of my students want to be able to defend themselves at some level from early on, so Kyu tests include increasing levels of resistance randori and execution of waza without foreknowledge of the attack (the range of attacks increases as rank goes up). In this part of the test the idea is successful application of waza and the use of reaction and adaptation to foster instinctive technique. This however is not part of the official required syllabus which must be met at a minimum to pass.
In our dojo tests are done to create an official environment of pressure where the student must perform accordingly. Although evaluation is done throughout, the test marks the watershed event as to whether one can really do what is required without constant prompting and correction by the Instructor. It also builds self esteem and confidence by placing one in a situation where one is doing an often public demonstration of what one knows in front of others who will know when one makes a mistake.
Just my 2 cents.