Refactor file corpus tests