The NEC electrical code test is given to certify the test-taker as a licensed electrician. Each state has different rules about certification, but you may be required to sit for a journeyman test or a master electrician test. Licensed journeymen can work unsupervised once successfully tested and certified, but each state has different rules for how much experience is needed before you can sit for the test.
A master electrician's license allows you to go into business for yourself, and obtain permits. In some states, certification isn't enough--you may be required to show proof of continuing education in order to keep your licence. You may also be required to recertify annually depending on the laws in your area. Electrical exams are often held at local colleges or government offices. Check with your local building department to learn where you must take the test and what the experience requirements are to sit for the exam.