I had an idea similar to this. One of the villains of the campaign was a Gnome Wizard and when he finally fought the party he was inside an Iron Golem (It had a hollowed out chest that he could sit inside with a iron lid.)
The fight was more or less more with the Iron Golem then the Wizard as he could not be harmed inside the Golem. (Though he would open the lid once in a while to fire out a spell before closing it.) He ended up just surrendering when the Golem was destroyed as he was largely helpless without it.
I've done something similar, except for me it was based on a Steam Golem from Kobold press Tome of Beasts. So basically a gnome in a steam-punk robot with the gnome opening a slot in the armor to cast spells and then closing it again quickly.
All went well until the barbarian climbed the thing and starting ripping the door off. I decided that since she was on the golem he could use it's steam blast on her every round and almost killed her (no small feat with a raging barbarian).
All fun and games until she manage to pry open the hatch and kill the wizard. Until the golem went berserk with no one at the controls of course.
