Refactor some file operation UI tests am: 3bdd3f567e
am: 790759a714

Change-Id: I3543d2330c36169f21c576e418c1b93ac0bad707