Commit ff2822cf by Sarina Canelake Committed by Diana Huang

Fix cms tests

parent ad7e0f94
......@@ -336,7 +336,8 @@ def create_new_course(request):
# Creating the course raises InvalidLocationError if an existing course with this org/name is found
new_course = modulestore().create_course(
course_key.org,
course_key.offering,
course_key.course,
course_key.run,
request.user.id,
fields=fields,
)
......
......@@ -33,14 +33,14 @@ class PersistentCourseFactory(SplitFactory):
# pylint: disable=W0613
@classmethod
def _create(cls, target_class, offering='999', org='testX', user_id=ModuleStoreEnum.UserID.test,
def _create(cls, target_class, course='999', run='run', org='testX', user_id=ModuleStoreEnum.UserID.test,
master_branch=ModuleStoreEnum.BranchName.draft, **kwargs):
modulestore = kwargs.pop('modulestore')
root_block_id = kwargs.pop('root_block_id', 'course')
# Write the data to the mongo datastore
new_course = modulestore.create_course(
org, offering, user_id, fields=kwargs,
org, course, run, user_id, fields=kwargs,
master_branch=master_branch, root_block_id=root_block_id
)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment