This may work sometimes but not all the time, and really depends on the dealership.
The problem with having someone work on your car these days is that there are more parts changers out there than real mechanics. My neighbor son is the head painter at my local Chevy dealership and he was telling me that they only have 4 real mechanics there, all the are parts changers.
That being said. When my sister was trying to get her truck fixed at her local dealership they told her that the throttle body had to be replaced because the SES light was lite and was for a bad TPS (code P0121). They also said they she should contact GM because GM may cover this repair. GM did extend the warranty on the TPS on her truck but for a different code. GM was contacted and they contacted the dealership and GM and the dealership both have declind cover this repair. The truck is only a couple months out of warranty and was purchased at this dealership. IMO they should have fixed this out of good faith. A little customer service does go along way...
What really gets me was this is a prime example of a parts changer! She did not let them fix the truck. I pulled and cleaned the throttle body and what do you know? The truck is fixed and has now passed emissions!!
This dealership and GM both failed on this service visit!