Whether slang, idioms, or colloquialisms, it is not wise to use such phrases in a written essay, which requires more formality than these offer.
A piece of cake -- a simple task
Let someone sleep on it -- let someone think about it carefully
Face the music -- accept the consequences
My two bits (as a relatively experienced teacher of TOEFL):
Idioms ("face the music" et al.) and phrasal verbs are considered too informal for the writing tasks. You may not lose marks but you will certainly score higher if you don't use idioms and phrasal verbs:-D