In most cases, a referral does not let you skip McKinsey Solve. Solve is usually a standard part of the process, and referrals are far more likely to influence application visibility than to remove required assessment steps.
Where referrals can help is earlier in the funnel or in how your candidacy is contextualized. They may improve the odds that your application gets serious consideration, but they should not be treated as a substitute for performing well on the assessment itself.
So the practical answer is to assume you will still need to take Solve and prepare accordingly. It is much safer to treat the referral as a helpful boost, not as a process shortcut.
If anything, a referral is best used to get a real shot. After that, you still need to convert on your own merits. You may also find it helpful to read whether everyone gets a McKinsey Solve invitation if you want a more structured way to practice this.