glasser / pymox

Automatically exported from code.google.com/p/pymox
Apache License 2.0
7 stars 11 forks source link

types.ClassType is not longer valid reference in py3 #65

Open sgpy opened 5 years ago

sgpy commented 5 years ago

Python 3.7.1 (v3.7.1:260ec2c36a, Oct 20 2018, 03:13:28) [Clang 6.0 (clang-600.0.57)] on darwin Type "help", "copyright", "credits" or "license" for more information.

from mox import Mox Traceback (most recent call last): File "", line 1, in File "/Users/sauravgupta/Desktop/modlettuce/assets/mox-0.5.3/mox.py", line 227, in class Mox(object): File "/Users/sauravgupta/Desktop/modlettuce/assets/mox-0.5.3/mox.py", line 232, in Mox _USE_MOCK_OBJECT = [types.ClassType, types.FunctionType, types.InstanceType, AttributeError: module 'types' has no attribute 'ClassType'

only valid types

[types.FunctionType, types.ModuleType, types.MethodType, ]