There are several ways that you can get sick and get pneumonia, but one way most people are unaware of is through a fungal infection. It is highly dangerous, especially in immunocompromised patients which is who is most likely to get infected http://www.ncbi.nlm.nih.gov/pmc/articles/PMC1271768/. As many as 90% of immunocompromised patients who are infected can face mortality.
To know for sure if you have fungal pneumonia there are several ways to diagnose it. One would be to culture the respiratory fluids, which is slow and time consuming, and can often lead to death if not done quickly enough. Another way is through checking antibodies, which is faster, but not as sensitive. There are other newer methods being developed all the time, hopefully something will be developed that can find it quickly and accurately.
To cure Pneumonia caused from Candida the most important thing is by prevention and keeping your immune system healthy. Eating right, and exercising properly will do more for you than any drug out there. In fact, drugs will weaken your body, only use them if you have to, otherwise it is best to avoid using anything that can hurt your body.
You can try getting rid of your Candida infection with natural antifungals (listed on this site), or using antifungals given to you by your doctor. They should both work, and you may want to try a combination for the best effect.