Heat the grill to its highest setting. Heat the oil in an ovenproof frying pan over a medium-high heat. Tip in the mushrooms and fry for 2 mins until mostly softened. Stir in the ham and spinach, and cook for 1 min more until the spinach has wilted. Season well with black pepper and a pinch of salt.
Reduce the heat and pour over the eggs. Cook undisturbed for 3 mins until the eggs are mostly set. Sprinkle over the cheese and put under the grill for 2 mins. Serve hot or cold.