Both your friend and you may have acquired an infection from a common source.
Both of you need the following tests to be done.
1. Chest X-ray is most important for both of you.
2. Complete blood count
3. Throat swab, culture, and sensitivity.
A course of antibiotic depending on the report will help both of you.
Wish you both early recovery.