When we write code, we should test it. No code has ever gone into production before at least doing some test runs. (Recognize the sarcasm!) There are different levels of tests that have different aims, technologies, industry practices, and names.
Unit tests, as the name suggests, test a unit of code. Integration tests test how the units integrate together. Smoke tests test a limited set of the features just to see that the code is not totally broken. There are other tests, until the final test, which is the proof of the work—the user acceptance test. The proof of the pudding is in the eating. A code is good if the user accepts it.
Many times, I tell juniors that the name user acceptance test is a bit misleading because it is not the user who accepts the result of a project, but the customer. By definition, the customer is the person who pays the bill...