pycharm 2.7 can no longer run unit tests

  • 1
  • 15

i just downloaded pycharm 2.7. all seems well except that i can no longer run my unit tests. i get the following:


Traceback (most recent call last):
File "/Applications/PyCharm.app/helpers/pycharm/django_test_manage.py", line 114, in <module>
utility.execute()
File "/Applications/PyCharm.app/helpers/pycharm/django_test_manage.py", line 90, in execute
PycharmTestCommand().run_from_argv(self.argv)
File "/Library/Python/2.7/site-packages/django/core/management/base.py", line 195, in run_from_argv
self.execute(*args, **options.__dict__)
File "/Library/Python/2.7/site-packages/django/core/management/base.py", line 222, in execute
output = self.handle(*args, **options)
File "/Applications/PyCharm.app/helpers/pycharm/django_test_manage.py", line 77, in handle
failures = TestRunner(test_labels, verbosity=verbosity, interactive=interactive, failfast=failfast)
File "/Applications/PyCharm.app/helpers/pycharm/django_test_runner.py", line 180, in run_tests
result = DjangoTeamcityTestRunner().run(suite, **kwargs)
File "/Applications/PyCharm.app/helpers/pycharm/django_test_runner.py", line 44, in __init__
super(DjangoTeamcityTestRunner, self).__init__(stream)
TypeError: must be type, not classobj


any ideas on how to get around this?
i fixed it by making this change.


*** django_test_runner.py    2013-02-08 13:30:14.000000000 -0800
--- django_test_runner.py.orig    2013-02-08 14:15:10.000000000 -0800
***************
*** 41,48 ****

class DjangoTeamcityTestRunner(BaseRunner):
def __init__(self, stream=sys.stdout, **options):
! BaseRunner.__init__(self, stream)
! #super(DjangoTeamcityTestRunner, self).__init__(stream)

def build_suite(self, *args, **kwargs):
EXCLUDED_APPS = getattr(settings, 'TEST_EXCLUDE', [])
--- 41,47 —-

class DjangoTeamcityTestRunner(BaseRunner):
def __init__(self, stream=sys.stdout, **options):
! super(DjangoTeamcityTestRunner, self).__init__(stream)

def build_suite(self, *args, **kwargs):
EXCLUDED_APPS = getattr(settings, 'TEST_EXCLUDE', [])