Notwithstanding any other law, a provision in a contract or settlement agreement entered into on or after January 1, 2019, that waives a party's right to testify in an administrative, legislative, or judicial proceeding concerning alleged criminal conduct or alleged sexual harassment on the part of the other party to the contract or settlement agreement, or on the part of the agents or employees of the other party, when the party has been required or requested to attend the proceeding pursuant to a court order, subpoena, or written request from an administrative agency or the Legislature, is void and unenforceable.
Ca. Civ. Code § 1670.11