Based on the story of the same name from Toby the Tram Engine.
There's a quarry near Thomas' branch line. However, he gets in trouble with a policeman by going across the public road without cowcatchers and sideplates. When The Fat Controller hears about it, he buys Toby who brings Henrietta with him.