Fixed test cases after moving metadata first