I know someone who took an AP test without taking the class first, and did well on the test. I don’t think that universities considered it in the applications process (the student was going to get into her first choice anyway). She did get full AP credit for the associated course – the equivalent to one full year course.
If you want to do it, then do it for the credit, not for the “bump” in admissions.