Refactor SetAliasesTest

Bug: 51681
Change-Id: I0ebd09eb1a4cd33927ffcee276f1adf441ed4b57