Fixed unit tests for Bug 971090
(cherry picked from commit 9ae9b275beca6f17d2f31bf638b9e384d8260376)
change event in confirm controller and clean code in preview controller
(cherry picked from commit 06bd371196c81125aa9974684a93ac9cc8d69016)
fix confirm controller test
fix review nits