A bill allowing the state to give graduation proficiency tests to high school students in any grade level has cleared the New Jersey Senate, which voted 21 to 7 in favor of the measure Thursday.

The measure advanced nearly two months after a court ruled that the state's testing policy was illegal. New Jersey had required students to take exams called PARCC in Algebra 1 and 10th-grade English in order to graduate.

But that contradicted law, which stated that students must pass a single test in 11th grade in order to graduate, a state appellate court ruled Dec. 31.

The Senate bill would change the law to allow the state to give "an assessment or assessments" for graduation and eliminate the requirement that it be given in 11th grade. The Assembly is expected to vote on the bill Monday.

While the bill would address problems in state graduation policy, it's not the solution that many education advocates wanted to see.

They have called for New Jersey to suspend and ultimately abolish the requirement that students pass a standardized test to graduate. In the U.S., only 12 states require what's known as "exit testing."

Critics say it compels teachers to narrow their focus in the classroom to what is covered by the test, and puts low-income, minority and special-needs students at a disadvantage. Advocates say the testing ensures students have met high school learning standards and are prepared for college.

Advocates are also concerned that the open language of the bill could be used to justify multiple tests. The bill was sponsored by Teresa Ruiz, D-Essex, in the Senate and Pamela Lampitt, D-Camden, in the Assembly.

The debate comes as New Jersey is working to develop a new state exam, after Gov. Phil Murphy promised to phase out PARCC, named for the Partnership for Assessment of Readiness for College and Careers, a group of states that developed the exams.

More:NJ reaches deal on high school graduation testing

More:New Jersey will move away from PARCC testing, but the transition could take years

More:How will LGBT history be taught in New Jersey schools after new law?

The bill was passed as the state seeks a long-term fix for its graduation standards.

When the court issued its ruling, it created confusion for 170,000 juniors and seniors who had already passed one or both PARCC tests. But last week, New Jersey officials announced that the state had reached a settlement that clears a path for those students to graduate.

It allows them to use passing scores on PARCC or other approved standardized tests, such as the SAT, ACT or the military placement exam to graduate. Students can also use a last-resort work portfolio to prove graduation readiness.

The court agreement provided the Department of Education with more time to propose new graduation testing rules for the classes of 2021 and 2022, who are current freshman and sophomores, respectively.