Fixed a redudancy on the test code