Our main concern is with the date of the passing smog inspection. Was the vehicle in your possession during the time the smog check was obtained and in no way were you involved with driving your Audi to the smog check station? If so, we have a big problem. More than likely the smog check was obtained fraudulently. We recommend getting exact dates... purchase date (possession of vehicle) and inspection date. If there is a discrepancy, please contact your local DMV Field Investigators Office at (800) 777-0133. They will send an investigator out to the used car dealership to look into this matter further. They will also contact the Bureau of Automotive Repairs and have one of their investigators pay a visit to the smog check station where the vehicle was inspected also.
If there is no date discrepancy and perhaps CarFax had wrong smog check date information, than unfortunately not much can be done. You may still choose to contact the DMV and BAR if you feel the vehicle could not have or should not have been able to pass the smog test, but if some time passed between the time you bought the Audi and when the problems occurred, the DMV or BAR may not be able to provide you any assistance. If you purchased any sort of warranty with the Audi, or if the vehicle had limited warranty, you may want to contact the dealership.
Look up your vehicle's smog check history.
As for the fuel pump needing replacement and the air or vacuum leak which your mechanics mentioned, we can not be certain that the two are related without a hands-on diagnosis. Also, unless the vacuum leak(s) triggered the check engine light to turn on, the vehicle may have been able to pass the smog check.