Engine Light on 2005 GMC Sierra

How or can you reset a Service Engine soon light on a 2005 GMC sierra? My husband has fixed the “problems” that he has and it still pops on, which caused him to not pass a state inspection. He also did not pass because the fuel injectors on his truck were dirty and was told once cleaned he needs to drive it for 300 miles to pass an emissions test, is that true?