The win, coupled with defeat for Carlisle, means Rovers will be promoted if they can win their last game at Cheltenham next Saturday.
Goalkeeper Dean Brill saved Luton from a thrashing as he pulled off a serious of brilliant saves – including four in the first 10 minutes.
Doncaster made a blistering start and Paul Green fired inches wide following a splendid move in the second minute before Brill’s reflexes denied Matt Mills twice in the space of seconds and he then dived full-length to prevent James Coppinger and Gareth Roberts from scoring.
Brill made another unbelievable save to keep out a cracking effort from Gareth Taylor in the 20th minute but he was finally beaten 14 minutes later.
The Luton keeper managed to parry a powerful header from Mark McCammon at full stretch but the ball fell to the feet off Mills who could not miss from point-blank range, but the home side deservedly wrapped up the points nine minutes from time when McCammon scored with a glancing header from Gareth Roberts’ cross.