I was trying to preserve the ordering, but we sort all the args anyway. Using sets and subtracting them performs much better than list comprehensions.
Make the tests use nose instead of unittest, and use properly parameterized arguments. This makes it a lot easier to see what fails.