In the past Apple has not voided warranty of customer opened machines. Now if they determine a problem is the result of faulty hardware repair/upgrade not by an ACS provider then yes they will deny coverage of effected components. I.e. if your hard drive fails and they suspect you have opened the machine up for whatever reason at some point, they are most likely going to replace the drive with no complaints.
Of course accidentally breaking the glass is a guaranteed out of pocket repair...