Fixed pkg_resources use in @patch decorators.