Fault Diagnosis for Switched Systems with Time Delay