moved custom class pairs out of the namespace and all tests pass