First of all, the best way is to prepared well in advance of the test. That means you really have to pay attention in class and take notes. If you don't get something that the teacher just said, ask a question.
Second, always do the homework. The homework makes all that new knowledge stick and helps you so much when it comes to test time.
Anyways, you should always do practice problems in the book especially those that the teacher went over. Keep practicing. Go over things you don't know or aren't sure about. Check your answers too!