Unless the defendant can invoke the confidential marital communications privilege, she cannot prevent her spouse from testifying against her if he decides to do so.
This form of the privilege applies only while the marriage exists. And numerous states have repealed the adverse spousal witness privilege entirely.
https://www.americanbar.org/groups/litigation/publications/litigation_journal/2018-19/summer/marital-privileges/#:~:text=Unless%20the%20defendant%20can%20invoke,adverse%20spousal%20witness%20privilege%20entirely.