Is it within the teste or just the scrotum? I'm assuming they checked for a hernia. If not, check for a hernia.
What part of the world do you live? Where were you 2-3 months ago? Traveled outside the country within the last year?
Did they give antibiotics?
Do you exercise? Jog, run, sports?
Might just be a simple bruise. Don't masterbate for awhile and let it heal. Don't touch it too much either, as it may cause more inflammation. Take ibuprofen or tylenol to ease the inflammation and pain. Also, keep your activities low. See what happens in a week or two.
Testicular pain can be due to injury, infection (Epididymitis or Orchitis) or inflammation, testicular torsion( most common in young men), excessive bicycle riding, hernia,varicocele or kidney or ureteric stones.
As there is no swelling or inflammation or redness of the scrotal sacs, so the chances of epidiymitis or orchitis are rare. In cases of hernia, a prominent bulge along with testicular pain is there and in cases of kidney or ureteric stones, pain during micturition may also be there.
Lab investigations like complete blood examination, urine examination, ultrasound lower abdomen and sometimes a urethral swab will help in diagnosis. Treatment will be started thereafter.My advise would be to consult a urologist.
I hope it helps.Take care and regards.