Some abilities, according to their description, are supposed to deal damage to an enemy, however, you can also erroneously shoot your own characters with them (normally you would receive an error notification with a pop-up message suggesting to select an enemy when trying to target friendlies with such abilities). So far this has been observed for C’Thun’s Mind Flay and Blink Fox’s Arcane Fling (it used to be an ability that just did damage to a target, but then it was reworked).
Additionally, while doing some testing, I’ve noticed another thing, which I haven’t really payed attention to before. When targeting an ability, a hovering tooltip explaining the action appears for many of them. It can state specifically, ‘Deal damage to an enemy,’ or ‘Deal damage to a character.’ In C’Thun’s case, there is no tooltip at all, while for Blink Fox it explicitly states, ‘Deal damage to an enemy.’