Completed tests for getting all elements in an array, swapping keys and values in a hash