C.P.
My 2 year old does the same thing! He spits and when I tell him no he points at me with a scowl on his face and says NO MOMMY! My limited experience is this (i also have a 5 year old) your daughter is testing your limits. She is trying to see if you are going to be consistant and if you are serious or not. Tell her if she spits she will get this punishment (if timeouts don't work, try taking something from her that she loves, sounds mean but she will learn and you won't have to do it too many times) and follow through. It's tiring, but she will stop doing that when she sees you mean it...be prepared though, she will move on to something else. It is also part of the age and she will grow out of it being so bad.
I have found that my kids test my limits every so often (yes my 5 year old still does it). They need to see what the rules are and if you will enforce them. They need the boundaries. good luck!