The carbonyl compounds which contains the $\mathrm{CH}_3 \mathrm{CO}-$ or the $\mathrm{CH}_3 \mathrm{C}(\mathrm{H})$ $(\mathrm{OH})$-compounds undergo the iodoform reaction. Benzyl alcohol, Methanol, Diethyl ketone, acetic acid do not give iodoform test.
Caution
Compounds that give positive Iodoform Test are Acetaldehyde, Methyl Ketone, Ethanol, Secondary Alcohols that contain methyl groups in alpha position.