Try turning everything off inside the car, (radio, fans, etc) and turn the ignition to run and not start. For a second or two you should be able to hear a humming of the fuel pump running. You may need an assistant to try and listen closer to the gas tank, as you may not be able to hear it from the drivers seat. Also, if your car is OBD 2 (1996+)then there should be an engine code stating a problem. However, if the problem is sporadic it may not trip a code, and the only way to find out may be to remove and test it.