Two union locals representing correctional officers will head to court Friday to challenge the state’s decision to close Bergin Correctional Institute in Mansfield last month to save more than $11 million.

The lawsuit filed by AFSCME Locals 1565 and 387 alleges that Gov. Dannel P. Malloy and Department of Correction Commissioner Leo Arnone may have trampled on the union’s constitutional rights when it made plans to close the facility. They say the increased number of inmates and fewer beds has created dangerous working conditions.

The lawsuit argues the prison guards have a constitutional right to be free from “a state created danger.”

William Gagne Jr., the attorney for the unions argues in his initial complaint, that correctional officers will be subjected to “increased danger…due to the sudden and significant increase in the inmate population of the receiving prisons and/or overcrowding in the receiving prisons.”

When inmates are sleeping on the floor of a gymnasium, there’s less time and space for recreational activity, which also leads to violence, the lawsuit says. There is less bathroom space. That makes inmates angry and frustrated but also raises health concerns because it increases the likelihood that communicable diseases will be transmitted, it says.

Access to facility cafeterias, commissaries and medical treatment would also be reduced, making for angry inmates and more opportunities for officers to be hurt or killed, the lawsuit says.

The lawsuit included some DOC statistics that show the number of inmates outnumber the number of beds at 12 of the state’s facilities.

But those statistics don’t add up for the state, which says there are fewer inmates now than there were a year ago.

Statistics compiled by the Office of Policy and Management’s Criminal Justice division show 18,500 beds and only about 17,600 inmates.

Michael Lawlor, undersecretary for criminal justice policy, noted back in August that the ratio will tilt further when the state opens about 400 beds in the North Block of Cheshire Correctional Institution.

“[The claims in the injunction] don’t seem to be borne out by the actual prison statistics right now,” Lawlor said.

But whether the state’s prisons are overcrowded won’t be what’s argued in court Friday. Instead, attorney’s will argue over whether the union even has enough standing to bring the lawsuit against the state. The state will argue it’s protected by sovereign immunity and that the union just wants the judicial branch to intervene in executive branch budgetary decisions.

The two sides have already gone back and forth filing motions in the case. And the judge allowed for limited discovery to be done, which included deposing Corrections Commissioner Leo Arnone.

According to Arnone’s deposition, the time it took the unions to agree to the concession package made it all but impossible for him to find the necessary budget savings without closing Bergin. At that point in August, plans to close Bergin were too far along to reverse the decision to close it, he said.

“It didn’t make any financial sense at all to backtrack, especially given the fact that we fully expect most of this housing that we were doing, these unconventional housing units, to be closed sometime in—start closing in September and be completely closed in November,” Arnone testified.

But the state represented by Assistant Attorney General Steven Strom argues in its latest brief that the unions “admit there is no authority to support their claimed constitutional right.” He goes onto to argue that they even concede it in their reply to the court when they mention a similar case that was not decided in favor of correctional officers.

In that lawsuit the court found that while budget cutting may subject correctional officers to dangerous conditions, it doesn’t limit their rights to bring other complaints for injury, such as labor or tort laws. The unions are also fighting to re-open the prison.

Arguments in the case will begin at 11:30 a.m. in Hartford Superior Court.