Create a 3rd explicit shard for unit tests.

More accurately, this creates a 4th shard because the
last shard is always the default.
This commit is contained in:
Ben Patterson
2016-04-26 15:24:50 -04:00
committed by Clinton Blackburn
parent afc5b47ebe
commit d76f50d93b
41 changed files with 98 additions and 0 deletions

View File

@@ -8,6 +8,7 @@ import decimal
import ddt
import freezegun
from mock import patch
from nose.plugins.attrib import attr
from django.conf import settings
from django.core.urlresolvers import reverse
@@ -25,9 +26,13 @@ from course_modes.models import CourseMode, Mode
from openedx.core.djangoapps.theming.test_util import with_is_edx_domain
@attr('shard_3')
@ddt.ddt
@unittest.skipUnless(settings.ROOT_URLCONF == 'lms.urls', 'Test only valid in lms')
class CourseModeViewTest(UrlResetMixin, ModuleStoreTestCase):
"""
Course Mode View tests
"""
@patch.dict(settings.FEATURES, {'MODE_CREATION_FOR_TESTING': True})
def setUp(self):
super(CourseModeViewTest, self).setUp('course_modes.urls')