If a federal judge rules against a Biden administration policy, the judge’s courtroom is almost certainly in Texas.

Texas Attorney General Ken Paxton and conservative groups have waged a ferocious, and mostly successful, legal campaign against President Joe Biden’s agenda on immigration, health care, and other issues.

Former President Donald Trump’s stamp on the judiciary has aided their campaign against the Biden administration. Trump-appointed judges sit in remote courthouses like Victoria and Amarillo, where they are almost certain to hear the cases filed by Texas and its allies in those divisions.

“If the Biden administration believes they can force states to comply with their political agenda, my office will fight against their radical attempt at social change,” Paxton, whose reelection bid is in a GOP primary runoff with George P. Bush, said in a statement last year, as he announced a lawsuit filed in Amarillo challenging the US Equal Employment Opportunity Commission’s gender identity guidance.

Texas has reaped the benefits of its one-of-a-kind advantages in its legal battle with Biden. They include a judicial assignment system in some state district courts that allows plaintiffs to essentially choose their judges, as well as a federal circuit court with jurisdiction over Texas appeals that has been yanked further to the right by Trump’s appointees. Trump took office with several vacancies ready for him to fill, thanks in part to Senate Republicans’ refusal to advance his predecessor’s nominees.

The wave of court defeats Trump has suffered in lawsuits brought against his administration by Democratic state attorneys general and other liberals bears some resemblance.

The Supreme Court announced last month that it will hear the case this spring, after lower courts rejected Biden’s bid to end the program. The program’s termination was first halted by a Trump appointee, Judge Matt Kacsmaryk, who preside over 95 percent of civil cases filed in Amarillo, Texas – the division where Texas filed its “Remain in Mexico” case.

In the Texas v. Biden legal battles, immigration has been a particularly contentious battleground. However, the state has been successful on other fronts as well, including in vaccine mandate litigation, where Texas obtained rulings blocking Biden vaccine rules for certain health care workers and Head Start program employees.

As the division’s only active judge, another Trump appointee, Judge Drew Tipton, is assigned almost all civil cases filed in Victoria, Texas. He halted a deportation moratorium proposed by Biden at the start of his presidency, as well as Biden’s efforts to restructure the government’s immigration enforcement priorities. He is in charge of the state’s legal challenge to Biden’s minimum wage increase for federal employees, which was filed in Victoria last month by Texas and two other Republican states.

The Fort Worth division of Texas’ Northern District is also a popular venue for lawsuits against the Biden administration, with 90 percent of cases assigned to either Judge Mark Pittman, a Trump appointee, or Judge Reed O’Connor, a George W. Bush appointee with a conservative reputation. O’Connor ruled in favor of Navy SEALs who sought a religious exemption from the military’s vaccine mandate and has been assigned a case Texas filed in Fort Worth challenging the administration’s air travel mask mandate.

The imprint that Trump has left on the federal judiciary, with the help of Senate allies, is also bolstering Texas’ legal fight against Biden’s agenda.

Some of Trump’s district judges filled vacancies created by the Obama administration. Senate practice for district judgeships requires that the nominees be approved by their home state senators – both of whom are Republicans in Texas – before they move forward, allowing those senators to stall efforts to fill those seats. After leaving the White House, Obama left 11 district court vacancies in Texas unfilled.

Trump’s legacy extends to the 5th US Circuit Court of Appeals in New Orleans, where six of the 17 active justices are his appointees, with another six appointed by previous Republican presidents. This court has played critical roles in upholding lower court rulings against Biden.