The Obama administration likes to say it is both strict and humane in enforcing immigration laws. For years, agents of Immigration and Customs Enforcement have been instructed to focus on deporting serious criminals, not low-level offenders and others who pose no threat. President Obama and his homeland security secretary, Jeh Johnson, have eloquently defended such “prosecutorial discretion” as a wise use of law-enforcement resources.

But a deportation case from rural Louisiana makes a mockery of those policies and suggests that ICE is willing to work with corrupt police departments to further racial profiling, unjust detention and other civil-rights abuses.

The case arose in New Llano, a town of 2,500 near the Texas border, last May. Two Honduran men, Jose Adan Fugon-Cano and Gustavo Barahona-Sanchez, were picked up by New Llano police officers while waiting for work outside a motel. The officers demanded their papers. The men were charged with no crimes but were handed over to the Border Patrol and then to ICE, which detained them as unauthorized immigrants who had been deported before. As the men awaited deportation for more than 140 days, the New Orleans Workers’ Center for Racial Justice, an advocacy organization, filed a civil-rights complaint on their behalf, citing the baseless arrests.

The Homeland Security Department’s Office for Civil Rights and Civil Liberties investigated. It found the complaint credible. An internal email from the head of the office, Megan Mack, to the director of ICE, Sarah Saldaña, could not have been clearer: “The men appear to have been arrested, transported and detained for an extended period of time, without any local law-enforcement interest in charging them with a crime, solely for an immigration status check,” Ms. Mack wrote. “It seems clear,” she added, that the arrest “was based on their ethnicity and the way they were awaiting pickup for a job.”