ジミーは友達が自分をからかうことに慣れていた。

English Translation

Jimmy was accustomed to his friends making fun of him.

This is not a straightforward expression…
The English sentence uses an active form (making fun of), but we usually say this in a passive form (being made fun of) in Japanese.

My alternative translations are:

ジミーは友達にからかわれることに慣れていた。(formal)
ジミーは友達にからかわれても、いつもへっちゃらだった。(casual)

へっちゃら means “I’m totally okay with that, and don’t care of that”. Inserting いつも (always), making fun of him doesn’t mean a one-time action but repeated actions. So, you need いつも followed by へっちゃら if you mean “be accustomed to (a bad thing)”.