These other posters are pretty accurate. I've had several engines hung on my trainers. If the engine is there in the crate, for a simple a/c like a 172, for example, it can be 4 hours. If the oil lines have already been checked or rebuilt, the baffles, exhaust, accessories [like mags], etc. etc., that's about it, then a flight around the pattern [or a few] and taxi in to check for oil leaks, etc., it is still less than one day. This is assuming the mechanic is dedicating the time to do it all at once. I've seen some folks work an hour or two, move over to do an oil change or battery service for someone, come back, etc., and drag it out for a week.
What I do is talk to them, the shop. I make sure all the ducks are in a row as I wait for the engine to arrive. Are my exhaust system, heater, oil cooler, mags, baffles, etc. all checked and certified to go? Battery serviced, new engine mounts here [the rubber things, not the pipe frame part]. It goes amazingly fast and much easier than an automobile engine. [If there are turbos, etc., we're talking more time.]