Removed duplicate code in the test mode method/operator declarations

I was looking at adding a many operator that would work with existing test methods and noticed that this could be DRY'd up a bit. Didn't end up figuring out how to do the many operator but that is a side topic.

I know I could push this just wanted to sanity check that you are OK with it.