Raman - Refactor test code for upload page.