Test
As you can see in the test above, where Staraptor is faster, in the case that Staraptor uses U-turn and Metagross Pursuit, Pursuit will hit its target before it switches out, but not before U-turn is used.
So in your situation, Staraptor will use U-turn before Metagross and knock it out.