The cardiac stress test is used to detect the ability of the heart to work under stress. It is usually done under a controlled clinical environment. The stress is induced by making the person running on a treadmill, or it can also be induced with the help of medicines. An ECG machine is connected to the patient to record the findings.