After hours of testimony and debate, the Texas Senate tentatively approved of S.B. 4 which is designed to ban sanctuary cities. A ban on sanctuary cities was listed as an emergency item by Texas Governor Greg Abbott last week and the Governor reiterated the importance of passing S.B. 4 in an interview on The Chad Hasty Show earlier this week on KFYO. A final vote and expected passage of the legislation should come Wednesday in Austin.

Under the legislation authored by Texas State Senator Charles Perry, agencies in Texas that refuse to enforce federal immigration laws could lose millions of dollars in funds and could even face fines. If the legislation is passed in the Senate and House, officials who promote sanctuary city policies could face jail time.

According to the Dallas Morning News, Sen. Perry said that rule of law is what is at stake with sanctuary cities.

"What's at stake here is the rule of law," said Sen. Charles Perry, R-Lubbock, the bill's author. "What's at stake is inconsistently applying laws across this country as well as this state."

While Republican lawmakers had pushed for legislation outlawing sanctuary cities, other groups have come out strongly against the measure. Democrats, some business groups, and some law enforcement agencies have spoken out against a ban on sanctuary cities.

Texas Governor Greg Abbott praised the Senate and Senator Perry for passage of S.B. 4 in a statement according to the Texas Tribune.

"Today's action in the Senate helps ensure that Sheriffs and officials across Texas comply with federal immigration laws and honor Immigration and Custom Enforcement detainer requests that keep dangerous criminals off of our streets," the statement read in part. "I want to thank Senator Perry for his leadership on this issue and look forward to final passage in the Senate tomorrow.”

If the legislation passes Wednesday in the Senate, it will move on to the House. The House has shown no signs of moving fast on any issue yet and there is no guarantee that Perry's version of a sanctuary cities bill will pass in the House.

Watch: Gov. Abbott Discusses Sanctuary Cities, More Emergency Items