Fixed error in swap test case