Failing regents but pass class

If I passed the class but failed the regents would I have to attend summerschool for regents prep? If I fail the regents do I not get a credit for the class?