The emergency stop is the only exercise that comes without warning. At some point during the test the examiner will raise their hand and say 'Stop' in a firm voice. Your job is to bring the car to a halt quickly, safely, and without losing control.
As soon as you hear the command, apply the brake firmly but progressively. Squeeze rather than stamp: this gives you maximum stopping power without locking the wheels. Keep both hands on the steering wheel to maintain your direction. Depress the clutch just before the car stops to avoid stalling.
Once stopped, apply the handbrake and select neutral or park. Before moving off again, check your mirrors to see what is behind you. Signal if you need to, and only pull away when the road is clear.
The examiner will only ask for an emergency stop when it is safe to do so. They check behind for following traffic before giving the signal, and they will not ask you to stop where it would create a hazard.

