It depends on the rider and the type of bike. For a roadie from first conversation to walking out the door with the bike, maybe two hours on average. A more basic bike like a hybrid, a lot less.
A road bike needs specific fitting, setup, etc. However, the most expensive road bike I sold this past summer took about 15 minutes because the customer knew what he wanted, had all his accessories, so it was check out by service and payment. It takes me about 15 minutes to do sizing, then go over the bike list with the customer, pick the bike witin their budget, and move on from there. A rider "moving up", depending on how long it's been since they last purchased, I'll probably remeasure them. Sometimes I have to let the rider tell me, then I have to work with that if they are really wrong and let them experience the changes to work it out in their head so they begin to listen, and that can take a while.
Bottom line, as long as the customer needs, but I can control the process.