From dcc6f54409499d776478494aa1f3d8598e94cfe6 Mon Sep 17 00:00:00 2001 From: Don Mitchell Date: Mon, 3 Mar 2014 13:15:48 -0500 Subject: [PATCH] Change get_courses default branch to draft. We need to figure out how apps configure what default they want or ensure they get the one they want --- common/lib/xmodule/xmodule/modulestore/split_mongo/split.py | 4 ++-- .../xmodule/modulestore/tests/test_split_modulestore.py | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/common/lib/xmodule/xmodule/modulestore/split_mongo/split.py b/common/lib/xmodule/xmodule/modulestore/split_mongo/split.py index f48a68632f..da61e061a1 100644 --- a/common/lib/xmodule/xmodule/modulestore/split_mongo/split.py +++ b/common/lib/xmodule/xmodule/modulestore/split_mongo/split.py @@ -274,7 +274,7 @@ class SplitMongoModuleStore(ModuleStoreWriteBase): } return envelope - def get_courses(self, branch='published', qualifiers=None): + def get_courses(self, branch='draft', qualifiers=None): ''' Returns a list of course descriptors matching any given qualifiers. @@ -284,7 +284,7 @@ class SplitMongoModuleStore(ModuleStoreWriteBase): Note, this is to find the current head of the named branch type (e.g., 'draft'). To get specific versions via guid use get_course. - :param branch: the branch for which to return courses. Default value is 'published'. + :param branch: the branch for which to return courses. Default value is 'draft'. :param qualifiers: a optional dict restricting which elements should match ''' if qualifiers is None: diff --git a/common/lib/xmodule/xmodule/modulestore/tests/test_split_modulestore.py b/common/lib/xmodule/xmodule/modulestore/tests/test_split_modulestore.py index 653b2a2f70..d2121bffa1 100644 --- a/common/lib/xmodule/xmodule/modulestore/tests/test_split_modulestore.py +++ b/common/lib/xmodule/xmodule/modulestore/tests/test_split_modulestore.py @@ -163,8 +163,6 @@ class SplitModuleCourseTests(SplitModuleTest): "children") _verify_published_course(modulestore().get_courses(branch='published')) - # default for branch is 'published'. - _verify_published_course(modulestore().get_courses()) def test_search_qualifiers(self): # query w/ search criteria