The answer depends a lot on what you mean by "properly", but overall, you pretty much can't.
Some architectures postpone actual rendering as much as possible, so if some odd error occurs at a very late stage, there's no way to signal an error. However, these cases are very, very rare, and you'll likely get an error while setting up rendering - be sure to check your shader compilation logs, etc.
A lot of things can go wrong, so it's generally a good idea to pepper your code with glerror checks. Alternatively (or additionally) you may want to hit your program with gDEBugger, or whatever AMD is calling it these days.
Now, if by "properly" you mean from a driver/hardware developer point of view, you can always just flush, read back the framebuffer and do a compare with a "golden image"..