just as one planned; right where one wants; just as expected
Used when a situation develops exactly as someone intended, often with a nuance of the person being trapped or manipulated. Common in the phrase 思う壺にはまる (to fall into someone's trap, to play right into someone's hands).
彼が怒るのは相手の思う壺だ。
Getting angry is exactly what the other person wants.
If you take the bait, you'll be playing right into their hands.