My very inadequate answer to that is: we'd have to use the same criteria we use to determine the motivations and intent of people in other contexts and areas of our lives.
Truth is, lots of people have anti-social intent in their actions, while still finding ways to accomplish some, or all of their goals through legal means. Tax shelters, casinos strategically set at state lines, and duty free shops all allow people to avoid responsibilities for conduct for which they would be accountable in other locations or circumstances.
The thing that makes the Tennessee redistricting example so very interesting to me is that those who claim this gerrymandering as an example of malice based on race are all too quick to dismiss the fact that the person holding the seat currently is white. Some have said that one of the potential leading candidates is a black woman. I don't know if that is true, but it would be ironic if all those claiming the Rs are doing this out of racial malice had to acknowledge that Rs actually might increase the number of black representatives in congress.
If a black woman were elected to a seat that was gerrymandered based on "politics," would you find that a net gain, or a net loss to the political strength of the black population?