That depends mostly on the type and size (rotating inertia) of the pump, the pump's driver and to a somewhat lesser extent the momentum of the fluid about to through. In general, electric drives can stop rather quickly, where internal combustion engine drivers may have slower shutdown procedures.
What type of pump, size and driver type do you have?
Only put off until tomorrow what you are willing to die having left undone. - Pablo Picasso