I think you need to be more specific about why you don't want to testify. "I'd prefer not to" just sounds like "I just don't want to be involved in your messy drama." I wouldnt blame her for asking you again because she needs friends to be involved. But your way of helping her is NOT testifying. So I'd say to her, "I want to help you. But I did not witness [good stuff she thinks you'll testify to], I only remember seeing [bad stuff you would actually testify to]. Therefore you don't want me on the stand."
I agree you should be more specific with her even if it's uncomfortable.
We have friends who are in a custody battle/divorce and thankfully have not been asked to be involved. But we are only friends with one partner now. It makes me sad and we tried to remain friends with both but it didn't work out. The husband is my H's best friend and our daughter's godfather. We went to college with him and didn't meet his wife until a year or two before they got married. So it makes sense that it shook out this way but it's hard.