After Alito had been nominated McCain was very vocal in his support. He supported Alito in the Senate and in public.
He knew dang well he couldn't afford to vote against him, while setting up a POTUS run. His private statements about him having been seeing the light day recently.