Designed to indicate whether your physical equipment is in good working order, a nocturnal tumescence test tells the doctor whether you’ve had an erection during sleep. Normal, healthy men have three to five nocturnal erections nightly, most of which occur during REM (rapid eye movement) sleep.

If the test indicates you are having nighttime erections, it signals to your doctor that any erectile problems you may be having are likely to be psychological in origin rather than physiological.

The test can be done at home or in a special sleep laboratory, according to WebMD.

In the most simple form of this test, a snap gauge consisting of plastic film is fitted around your penis. The gauge is designed to break when subjected to certain pressures, specifically the pressure caused by an erection.

In a lab setting, your penis can be fitted with an electronic monitoring device that records the number and strength of erections that occur during the night.