Operator tests

Added some more test coverage for the operator class. Only did not know what to do about the add_rule() function. Not sure if it was needed, or if it was, how to really make a test for it.