How much time does it take to recover from a shoulder injury?

It depends. Recovery depends on the injury and whether surgery is needed. If no immediate surgery is needed than recovery should take 3-4 months. If you are not better by then you need to be reevaluated.
Variable. Recovery depends on what type of injury occurred. As a general rule of thumb, if the injury does not seem to be severe enough to warrant immediate evaluation, it is reasonable to give it at least 6 wks to get better. If there is still pain and loss of function it is time to see your doctor. If there is significant immediate pain and/or loss of function after injury, get an evaluation asap.