After a long delay, the Senate finally voted to confirm Loretta Lynch as the next U.S. Attorney General, making her the first African-American woman to fill the position.

President Obama initially announced Lynch as his nomination to head the U.S. Justice Department back in November. Following Obama's announcement, Senate Republicans stalled her confirmation process for weeks by refusing to vote on her nomination until they passed an anti-human-trafficking bill that included a controversial antiabortion provision. As a result, Lynch was forced to wait for over 165 days to be confirmed as Eric Holder's successor until the upper chamber approved her nomination in a 56-43 vote on Thursday, reports The Washington Post.

Nine Republican senators, including Senate Majority Leader Mitch McConnell and Sen. Lindsey Graham of South Carolina, voted in favor of Lynch, notes CNBC. However, the majority of Republicans voted nay or withheld their vote.

Earlier on Thursday, Sen. Ted Cruz urged Republicans to oppose her nomination on the floor, stating that Lynch was "unsuitable" for the job due to the views on immigrant rights to work that she expressed at her confirmation hearing.

"When asked further who has more right to a job, a United States citizen or a person who came to this country illegally, she responded, 'I believe that the right and the obligation to work is one that's shared by everyone in this country, regardless of how they came here,'" said the Texas senator and presidential contender, who withheld his vote. "Well, Mr. President, a very large majority of the American citizens would beg to differ. Rule of law matters," he added, according to a press release.

Sen. Marco Rubio, another 2016 presidential hopeful, also voted against Lynch's nomination.

"I opposed Loretta Lynch's nomination because of her failure to identify any limit on the president's ability to ignore the laws passed by Congress as well as her obvious enthusiasm for civil asset forfeiture, which can deprive innocent people of their property rights without due process," stated Rubio in a press release. "I could not support Ms. Lynch because of every indication she has given that she will put her support of the president's policies ahead of her support of the Constitution of the United States."

On the other hand, Senate Democrats like Bob Menendez expressed enthusiastic support for the new Attorney General.

"Loretta Lynch is a deeply respected and qualified nominee whose confirmation should have never fallen prey to partisan politics. At a time when our country requires strong leadership to confront the threat of terrorism and serious law enforcement issues in our communities, I am glad Senate Republicans finally dropped their shameful and divisive tactics that kept her from doing that job for far too long," he stated in a press release.