Testing and Debugging Custom Integrated Circuits