Adds a split_test_module XModule, that can choose one of its children
to display, based on a get_condition_for_user API added to the runtime.
To test, add something like this to an xml course, or make equivalent
tweaks in mongo.
<vertical url_name="split_test_vert">
<split_test url_name="split1" experiment_id="0" condition_id_to_child='{"0": "i4x://MITx/6.00x/html/split_test_cond0", "1": "i4x://MITx/6.00x/html/split_test_cond1"}'>
<html url_name="split_test_cond0">condition 0</html>
<html url_name="split_test_cond1">condition 1</html>
</split_test>
</vertical>
Also needs an experiment configured in the course policy json: e.g.
"user_partitions": [{"id": 0,
"name": "Experiment 0",
"description": "Unicorns?",
"version": 1,
"groups": [{"id": 0,
"name": "group 0",
"version": 1},
{"id": 1,
"name": "group 1",
"version": 1}]}]
(This particular snippet will work inside a course with org MITx
and course name 6.00x)
Co-Author: Sarina Canelake <sarina@edx.org>
Co-Author: Julia Hansbrough <julia@edx.org>
Co-Author: Diana Huang <diana@edx.org>
Co-Author: Calen Pennington <cale@edx.org>
[LMS-2095]
| Name |
Last commit
|
Last update |
|---|---|---|
| .. | ||
| data | Loading commit data... | |
| rendering | Loading commit data... | |
| templates/test | Loading commit data... | |
| xml | Loading commit data... | |
| __init__.py | Loading commit data... | |
| helpers.py | Loading commit data... | |
| test_annotatable_module.py | Loading commit data... | |
| test_capa_module.py | Loading commit data... | |
| test_combined_open_ended.py | Loading commit data... | |
| test_conditional.py | Loading commit data... | |
| test_conditional_logic.py | Loading commit data... | |
| test_content.py | Loading commit data... | |
| test_course_module.py | Loading commit data... | |
| test_crowdsource_hinter.py | Loading commit data... | |
| test_editing_module.py | Loading commit data... | |
| test_error_module.py | Loading commit data... | |
| test_export.py | Loading commit data... | |
| test_fields.py | Loading commit data... | |
| test_graders.py | Loading commit data... | |
| test_html_module.py | Loading commit data... | |
| test_import.py | Loading commit data... | |
| test_import_static.py | Loading commit data... | |
| test_lti_unit.py | Loading commit data... | |
| test_mako_module.py | Loading commit data... | |
| test_peer_grading.py | Loading commit data... | |
| test_poll.py | Loading commit data... | |
| test_progress.py | Loading commit data... | |
| test_randomize_module.py | Loading commit data... | |
| test_resource_templates.py | Loading commit data... | |
| test_self_assessment.py | Loading commit data... | |
| test_split_module.py | Loading commit data... | |
| test_stringify.py | Loading commit data... | |
| test_textannotation.py | Loading commit data... | |
| test_util_duedate.py | Loading commit data... | |
| test_util_open_ended.py | Loading commit data... | |
| test_utils_django.py | Loading commit data... | |
| test_video.py | Loading commit data... | |
| test_videoannotation.py | Loading commit data... | |
| test_word_cloud.py | Loading commit data... | |
| test_xblock_wrappers.py | Loading commit data... | |
| test_xml_module.py | Loading commit data... |