A federal judge will hear oral arguments later this month in a case that could decide whether the Wampanoag Tribe of Gay Head (Aquinnah) can ultimately open a casino on Martha’s Vineyard.

Judge F. Dennis Saylor IV has scheduled a hearing for Friday in U.S. District Court on a motion to dismiss the case.

At the hearing, lawyers for the tribe, state, the town of Aquinnah and the Aquinnah/Gay Head Community Association will all have a chance to argue the complicated legal question of sovereign immunity, which the tribe is claiming.

When Gov. Deval Patrick signed the Expanded Gaming Act into law in 2011, the Aquinnah tribe sought unsuccessfully to negotiate a tribal-state compact with Patrick for an off-island casino.

But Patrick has held firm that the tribe waived its rights to a casino in making a land deal in 1983 that was ultimately codified by Congress in 1987. The tribe agreed to abide by state and local zoning laws in that agreement.

Without the state’s support, the tribe failed to convince voters in Freetown and Lakeville to support a casino proposal brought forward in those towns by the Aquinnah tribe. That led to the tribe's decision to consider a high-stakes bingo hall on its island land. The tribe believes it has the rights to open such a Class II gambling facility, with bingo slots, machines that look and act like slot machines, without sharing any revenue with the state.

The lawsuit against the Aquinnah tribe was brought by Patrick in December 2013 in an attempt to block the tribe’s plans to open a casino in a vacant community building on the tribe’s reservation land. Patrick brought the suit in state court alleging the tribe breached its contract with the state in the 1980s land settlement agreement.

The tribe successfully moved to have the case heard in federal court, arguing the court has jurisdiction because of the Indian Gaming Regulatory Act of 1988, a federal law that gives tribes the right to locate casinos on Indian land under certain circumstances.

That has set off a series of claims and counter-claims seeking to dismiss the case.

The tribe has boasted support in a legal opinion offered by the National Indian Gaming Commission that its island lands qualify for Indian gaming. In essence, the opinion was that Indian gaming law supersedes land settlement agreements.

All of this set up the showdown currently playing out, mostly in court documents, at the John Joseph Moakley Courthouse in Boston.