People in 17 states, including Maryland and Virginia, who tried to buy groceries using electronic food-stamp cards were turned away from supermarkets Saturday as a result of a computer outage.

The system failure affected low-income individuals and families who receive food benefits through the Supplemental Nutrition Assistance Program (SNAP) and Women, Infants and Children program (WIC).

The outage occurred during a “routine test” of backup systems Saturday morning, Jennifer Wasmer, a spokeswoman for Xerox, which administers the program, said. By late Saturday, access had been restored.

After the system failed, SNAP and WIC beneficiaries in the affected states were unable to buy food using electronic benefit transfers.

“Beneficiary access to programs such as SNAP, TANF, and other programs has been restored to the 17 States where Xerox provides EBT service. Re-starting the EBT system required time to ensure service was back at full functionality,” Wasmer said in a statement.

Courtney Rowe, a spokeswoman for the U.S. Department of Agriculture, told the Associated Press that the outage was not related to the government shutdown.

Earlier Saturday, Brian Schleter, a spokesman for the Maryland Department of Human Resources, which provides services to low-income residents, confirmed the problems with the electronic benefits system. He said Maryland officials were in “close communication” with Xerox and were working to restore service as soon as possible.

More than 6,000 Maryland residents received food assistance last month, according to state data. It was unclear how many residents in Maryland were unable to obtain food Saturday. Virginia officials could not be reached for comment Saturday.

Before repairs were made, Wasmer suggested that beneficiaries “work with their local retailers, who can activate an emergency voucher system where available.”

“We appreciate our clients’ patience while we work through this outage as quickly as possible,” she said.

Many people had to walk away from full grocery carts Saturday.

Richard Elwell, who lives in Chevy Chase, said someone he knows went to two grocery stores, and was unable to buy food at either. His first thought when heard about the problem: the government shutdown.

“I was wondering what was going [on],” Elwell said.

But Wasmer said the shutdown was not the problem.

USDA officials have said that food benefits were not in immediate jeopardy from the shutdown. Funds would be available through late October, officials said.