Thanks for posting your query.
You are most likely suffering from acute viral upper respiratory tract
infection with epididymo-orchitis
Presence of cough
along with painful testicles suggest the diagnosis.
You should consult with internal medicine specialist and should go for thorough check up.
You should also go for ultrasound
imaging of scrotum
& urine routine & microscopy examination.
Although these infections are viral in origin, yet you should take antibiotics for prevention of secondary bacterial infection.
You should also take cough suppressants, analgesics.
You should perform gargles three times in a day with lukewarm water & pinch of salt.
You should wear loose pants.
Dr. Mayank Bhargava