The U.S. Federal Reserve said Wednesday that the nation’s largest banks appear to have the financial muscle to withstand ugly economic scenarios, like a housing market crash or double-digit unemployment.

But two banks — Deutsche Bank and Santander Holdings — failed the Fed’s annual stress test. Both failed the tests last year and Santander has become the first bank to fail it for three consecutive years.

By failing these stress tests, the banks are prohibited from issuing shareholder payouts (whether through dividends or stock buybacks) without Fed authorization. The test results showed the two foreign banks continue to have “material unresolved supervisory issues that critically undermine its capital planning process,” the Fed said in its report, which was released after markets closed Wednesday.

Deutsche Bank Fed stress test The Deutsche Bank logo. Germany’s biggest lender failed an important annual stress test administered by the U.S. central bank. Photo: Daniel Roland/AFP/Getty Images

But the Fed said the two banks are making progress and did not announce any punitive actions against them. The Fed has said in the past it could impose additional regulatory action, including cease-and-desist orders, for banks that show an ongoing unwillingness to correct deficient behavior.

The stress tests were administered to 33 major banks operating in the U.S. using various hypothetical scenarios, including how banks would fare if the U.S. economy tipped into crisis. For the first time, the Fed asked how banks could handle interest rates falling into negative territory. The results showed the nation’s largest banks appear to have the financial muscle to survive, according to the Fed.

The Fed also said Morgan Stanley must address certain weaknesses and resubmit a plan by the end of the year. Buffalo, New York-based M&T Bank Corp. initially fell short of capital requirements (the amount banks need in cash to cover losses), but the bank issued an adjusted plan allowing it to pass.

Under the 2010 Dodd-Frank financial overhaul law, all banks with more than $10 billion in assets must undergo annual regulatory stress tests that measure how well they would fare under certain disastrous economic conditions. They’re one way to help ensure banks have enough capital and contingencies in place to survive dire economic situations.