Commit 66287d0d by Chris Dodge

fix test to use the new create_item method rather than clone_item, which has…

fix test to use the new create_item method rather than clone_item, which has been deprecated, and thus breaking the test
parent 96a9d741
...@@ -816,12 +816,9 @@ class ContentStoreToyCourseTest(ModuleStoreTestCase): ...@@ -816,12 +816,9 @@ class ContentStoreToyCourseTest(ModuleStoreTestCase):
self.assertGreater(len(verticals), 0) self.assertGreater(len(verticals), 0)
new_component_location = Location('i4x', 'edX', 'toy', 'video', 'new_component')
source_template_location = Location('i4x', 'edx', 'templates', 'video', 'default')
module_store.clone_item(source_template_location, new_component_location)
parent = verticals[0] parent = verticals[0]
module_store.update_children(parent.location, parent.children + [new_component_location.url()])
ItemFactory.create(parent_location=parent.location, category="video", display_name="untitled")
root_dir = path(mkdtemp_clean()) root_dir = path(mkdtemp_clean())
......
...@@ -133,7 +133,7 @@ class VideoDescriptor(VideoFields, ...@@ -133,7 +133,7 @@ class VideoDescriptor(VideoFields,
Override the base implementation. We don't actually have anything in the 'data' field Override the base implementation. We don't actually have anything in the 'data' field
(it's an empty string), so we just return a simple XML element (it's an empty string), so we just return a simple XML element
""" """
return etree.fromstring('<video />') return etree.Element('video')
def _parse_video_xml(video, xml_data): def _parse_video_xml(video, xml_data):
......
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