Don't panic. There is a blood test that your friend can have to find out if they are infected. This test detects the presence of antibodies to the virus, (which would mean that your friend had been in contact with it.) It usually takes people 12-14 weeks after being exposed to the virus to develop the antibodies. Therefore if you have unprotected sex and want to be tested the next day or week, you will be advised to wait for at least three months after your high risk activity.
It is very important during the waiting period that your friend abstains from participating in high risk activities so as to prevent passing on any potential H.I.V. transmission.
They can speak to a doctor about their concerns. It usually takes about two weeks for blood test results to come back.