If your school is a SolidWorks Academic Certification Provider and on subscription, you can get the "CSWA-Academic" exam for free.
If not, you'll have to purchase the "CSWA-Mechanical Design" exam, or hunt for vouchers from resellers or certified partners (like SolidProfessor).