Washington (CNN) In recent weeks, the government has stumbled trying to explain its plan for reunifying families in the wake of its much-criticized family separations policy at the border.

But newly reviewed court filings show that the byzantine system that has resulted in thousands of children separated for weeks and months from parents elsewhere in government custody was not an accident. It was always the design.

In fact, one of the women in an ongoing lawsuit over family separations was apparently one of the first separations that took place during a quiet pilot of the policy last year. The pilot program has been previously reported, but took on new attention on the heels of an NBC report about it Friday.

A government attorney admitted in court just days before the border-wide initiative was unveiled in early May that there was never a plan for parents like her to be proactively reunited with their kids.

And an analysis of the purported success of the pilot shows that the Department of Homeland Security's justification that the program worked as a deterrent was likely based on dubious data.

A DHS official confirmed Friday that the agency first tested the policy of prosecuting parents caught illegally crossing the border in the El Paso sector in Texas from July to October of last year. The pilot had been previously reported, but was not widely known. NBC reported the effort anew Friday.

Ms. C, as she is known in court filings, was apprehended crossing the border illegally in late August 2017 and prosecuted in El Paso, according to court documents. She asked for asylum and in the midst of the legal process, the government took her 14-year-old son from her, sending him to a Health and Human Services facility in Chicago. They were separated for months.

Her story is central to a case brought by the American Civil Liberties Union challenging family separations -- filed before the zero tolerance pilot was publicly known. The judge in that case has now ordered the government to reunite families separated by prosecution within 30 days.

The case was argued in court May 4 -- a few days before the border-wide zero tolerance policy became public.

There was no mention during the hearing of her being prosecuted under zero tolerance. The government attorney did note that prosecution could be a reason that families were separated, and that would be valid under the law, but made no mention of a widespread policy to do so.

But regarding Ms. C, the judge asked the government attorney whether any plan existed to help women like her -- separated from their children because of prosecution -- reunite with the children. The lawyer's response is a clear indication that the government did not develop any such effort.

In fact, the government readily admitted that the plan all along was precisely what came to pass: parents scrambling while in government detention to track down their kids.

"The way I understand the process -- that was my reference to the black hole -- is the person gets out of custody for the conviction they are serving, they then go into ICE detention to pursue immigration- and asylum-related matters, but their child is somewhere else. ... And there is no procedure or mechanism for that parent to reunite with their child, absent hiring lawyers or pursuing it on their own," Judge Dana Sabraw asked the attorney, according to the hearing transcript. "Is that correct?"

"I think that is correct," Justice Department attorney Sarah Fabian replied. "At that point the separation has occurred because of the prosecution. And that person then, when released from criminal custody, is being taken into ICE custody. At that point, again, the separation has already occurred. The minor is in ORR custody. The only release from ORR (Office of Refugee Resettlement) custody is subject to the TVPRA (law), so subject to a finding of a suitable custodian. And until -- while that individual remains in custody they are not going to be a suitable custodian, nor is there the ability to detain them together because they are then in ICE custody."

DHS announced it would implement the border-wide prosecution policy three days later.

Dubious data

The pilot program was touted by DHS in early May when the department provided background information to reporters on its zero tolerance plan.

At the time, DHS said the number of illegal crossings "dropped by 64 percent" when the El Paso sector tried prosecuting all adults, including parents.

"This decrease was attributed to the prosecution of adults amenable to prosecution for illegal entry while risking the lives of their children. Of note, the numbers began rising again after the initiative was paused," the background information stated.

An analysis bar chart that was shared with CNN showed that the 64% was calculated by comparing apprehensions in October 2017 to those in October 2016.

But a fuller analysis of the data shows that one could just as easily conclude there was no effect from the initiative -- and if there was, it was not something that would necessarily translate if applied to the whole border.

It is true that in the El Paso sector, illegal crossings were down about 63% in the month of October 2017 compared with October 2016, according to published Border Patrol data. The analysis DHS did covered only October 1-26 for each month, thus the slight discrepancy.

But apprehensions in 2016 were unusually high -- the beginning of a wave of migration to the southwest border that preceded Trump's election and inauguration.

Across the board, apprehensions at the southern border in October 2017 were about 45% lower than the year before. And in the El Paso sector, the crossings in October 2017 were very close to the numbers in the same month in 2015.

While the drop was more pronounced in the El Paso sector then the whole border, the data shows that was likely because crossings merely shifted elsewhere.

Neighboring sector Big Bend saw a 17% increase in apprehensions from the previous year, and neighboring sector Tucson had only a 35% decrease in apprehensions.

A DHS official stood by the claim that the effort worked Friday

"It is indisputable that when there are consequences for illegal actions, we see an effect on apprehensions at the border," the official said.

There was a wide disparity in the change in numbers year over year across sectors -- an indication of the fact that migration along the border shifts and ebbs based on a number of factors. Those could include changes in smuggling routes, sector-by-sector crackdowns or even weather conditions.

Experts have long said any policy designed to deter migrants from crossing into the US by changing US laws would have a temporary effect at best. Without addressing the conditions back home that push them north, experts say, the migration will continue