Added a new test function for integerswap