The thermostat is connected by two wires. The wires are connected with slip on connectors or a wiring harness. Firmly pull the connectors or harness off of the terminals (do not pull on the wire). You may need to use a pair of needle-nose pliers to remove the connectors. Inspect the connectors and the terminals for corrosion. If the connectors are corroded they should be replaced.
Test the thermostat for continuity using a multitester. Set the multitester to the ohms setting X1. Place a probe on each terminal. The multitester should display a reading of zero when the thermostat is cold and a reading of infinity when it is warm (40 to 90 degrees F depending on the model). If the thermostat does not pass this test it should be replaced.