Check the can for an expiration date. You'll know they're bad if that date is past. The next things you should do is check the shape of the can. If the ends are warped at all, throw the can away. Your final test is the look and taste of the tomatoes. If something seems off, dump them.
Check for a good seal that is concave in the middle. Look to see if the contents have rising bubbles or if they are very dark in color. Look for leaking on the can. Finally, watch to see if they explode upon opening or smell funny.