Unverified Commit a0df76e1 by Harry Rein Committed by GitHub

Merge pull request #16903 from edx/HarryRein/entitlements-jasmine-tests-requireJS

Remove dependency on Popper.js
parents 02573a31 54734841
...@@ -10,7 +10,8 @@ ...@@ -10,7 +10,8 @@
'js/learner_dashboard/models/course_entitlement_model', 'js/learner_dashboard/models/course_entitlement_model',
'js/learner_dashboard/models/course_card_model', 'js/learner_dashboard/models/course_card_model',
'text!../../../templates/learner_dashboard/course_entitlement.underscore', 'text!../../../templates/learner_dashboard/course_entitlement.underscore',
'text!../../../templates/learner_dashboard/verification_popover.underscore' 'text!../../../templates/learner_dashboard/verification_popover.underscore',
'bootstrap'
], ],
function( function(
Backbone, Backbone,
......
...@@ -32,6 +32,7 @@ ...@@ -32,6 +32,7 @@
'js/groups/views/cohorts_dashboard_factory', 'js/groups/views/cohorts_dashboard_factory',
'js/discussions_management/views/discussions_dashboard_factory', 'js/discussions_management/views/discussions_dashboard_factory',
'js/header_factory', 'js/header_factory',
'js/learner_dashboard/course_entitlement_factory',
'js/learner_dashboard/unenrollment_factory', 'js/learner_dashboard/unenrollment_factory',
'js/learner_dashboard/program_details_factory', 'js/learner_dashboard/program_details_factory',
'js/learner_dashboard/program_list_factory', 'js/learner_dashboard/program_list_factory',
......
...@@ -100,6 +100,7 @@ ...@@ -100,6 +100,7 @@
'string_utils': 'js/src/string_utils', 'string_utils': 'js/src/string_utils',
'utility': 'js/src/utility', 'utility': 'js/src/utility',
'draggabilly': 'js/vendor/draggabilly', 'draggabilly': 'js/vendor/draggabilly',
'bootstrap': 'common/js/vendor/bootstrap.bundle',
// Files needed by OVA // Files needed by OVA
'annotator': 'js/vendor/ova/annotator-full', 'annotator': 'js/vendor/ova/annotator-full',
...@@ -165,6 +166,9 @@ ...@@ -165,6 +166,9 @@
'backbone-super': { 'backbone-super': {
deps: ['backbone'] deps: ['backbone']
}, },
'bootstrap': {
deps: ['jquery']
},
'string_utils': { 'string_utils': {
deps: ['underscore'], deps: ['underscore'],
exports: 'interpolate_text' exports: 'interpolate_text'
......
...@@ -74,6 +74,7 @@ ...@@ -74,6 +74,7 @@
'mathjax_delay_renderer': 'coffee/src/mathjax_delay_renderer', 'mathjax_delay_renderer': 'coffee/src/mathjax_delay_renderer',
'MathJaxProcessor': 'coffee/src/customwmd', 'MathJaxProcessor': 'coffee/src/customwmd',
'picturefill': 'common/js/vendor/picturefill', 'picturefill': 'common/js/vendor/picturefill',
'bootstrap': 'common/js/vendor/bootstrap.bundle',
'draggabilly': 'xmodule_js/common_static/js/vendor/draggabilly', 'draggabilly': 'xmodule_js/common_static/js/vendor/draggabilly',
// Manually specify LMS files that are not converted to RequireJS // Manually specify LMS files that are not converted to RequireJS
...@@ -186,6 +187,9 @@ ...@@ -186,6 +187,9 @@
deps: ['underscore', 'jquery'], deps: ['underscore', 'jquery'],
exports: 'Backbone' exports: 'Backbone'
}, },
'bootstrap': {
deps: ['jquery']
},
'backbone.associations': { 'backbone.associations': {
deps: ['backbone'], deps: ['backbone'],
exports: 'Backbone.Associations' exports: 'Backbone.Associations'
......
...@@ -47,7 +47,6 @@ from student.models import CourseEnrollment ...@@ -47,7 +47,6 @@ from student.models import CourseEnrollment
}); });
}); });
</script> </script>
<%static:webpack entry="Bootstrap"></%static:webpack>
<%static:require_module module_name="js/learner_dashboard/unenrollment_factory" class_name="UnenrollmentFactory"> <%static:require_module module_name="js/learner_dashboard/unenrollment_factory" class_name="UnenrollmentFactory">
UnenrollmentFactory({ UnenrollmentFactory({
urls: { urls: {
......
...@@ -9,7 +9,6 @@ from openedx.core.djangolib.js_utils import ( ...@@ -9,7 +9,6 @@ from openedx.core.djangolib.js_utils import (
%> %>
<%block name="js_extra"> <%block name="js_extra">
<%static:webpack entry="Bootstrap"></%static:webpack>
<%static:require_module module_name="js/learner_dashboard/program_details_factory" class_name="ProgramDetailsFactory"> <%static:require_module module_name="js/learner_dashboard/program_details_factory" class_name="ProgramDetailsFactory">
ProgramDetailsFactory({ ProgramDetailsFactory({
programData: ${program_data | n, dump_js_escaped_json}, programData: ${program_data | n, dump_js_escaped_json},
......
...@@ -88,8 +88,7 @@ from pipeline_mako import render_require_js_path_overrides ...@@ -88,8 +88,7 @@ from pipeline_mako import render_require_js_path_overrides
% if uses_bootstrap: % if uses_bootstrap:
## xss-lint: disable=mako-invalid-js-filter ## xss-lint: disable=mako-invalid-js-filter
<script type="text/javascript" src="${static.url('common/js/vendor/popper.js')}"></script> <script type="text/javascript" src="${static.url('common/js/vendor/bootstrap.bundle.js')}"></script>
<script type="text/javascript" src="${static.url('common/js/vendor/bootstrap.js')}"></script>
% endif % endif
<script> <script>
......
...@@ -52,7 +52,7 @@ COMMON_LOOKUP_PATHS = [ ...@@ -52,7 +52,7 @@ COMMON_LOOKUP_PATHS = [
NPM_INSTALLED_LIBRARIES = [ NPM_INSTALLED_LIBRARIES = [
'backbone.paginator/lib/backbone.paginator.js', 'backbone.paginator/lib/backbone.paginator.js',
'backbone/backbone.js', 'backbone/backbone.js',
'bootstrap/dist/js/bootstrap.js', 'bootstrap/dist/js/bootstrap.bundle.js',
'hls.js/dist/hls.js', 'hls.js/dist/hls.js',
'jquery-migrate/dist/jquery-migrate.js', 'jquery-migrate/dist/jquery-migrate.js',
'jquery.scrollto/jquery.scrollTo.js', 'jquery.scrollto/jquery.scrollTo.js',
...@@ -60,7 +60,6 @@ NPM_INSTALLED_LIBRARIES = [ ...@@ -60,7 +60,6 @@ NPM_INSTALLED_LIBRARIES = [
'moment-timezone/builds/moment-timezone-with-data.js', 'moment-timezone/builds/moment-timezone-with-data.js',
'moment/min/moment-with-locales.js', 'moment/min/moment-with-locales.js',
'picturefill/dist/picturefill.js', 'picturefill/dist/picturefill.js',
'popper.js/dist/umd/popper.js',
'requirejs/require.js', 'requirejs/require.js',
'underscore.string/dist/underscore.string.js', 'underscore.string/dist/underscore.string.js',
'underscore/underscore.js', 'underscore/underscore.js',
......
...@@ -48,7 +48,6 @@ from student.models import CourseEnrollment ...@@ -48,7 +48,6 @@ from student.models import CourseEnrollment
}); });
}); });
</script> </script>
<%static:webpack entry="Bootstrap"></%static:webpack>
<%static:require_module module_name="js/learner_dashboard/unenrollment_factory" class_name="UnenrollmentFactory"> <%static:require_module module_name="js/learner_dashboard/unenrollment_factory" class_name="UnenrollmentFactory">
UnenrollmentFactory({ UnenrollmentFactory({
urls: { urls: {
......
...@@ -25,7 +25,6 @@ module.exports = { ...@@ -25,7 +25,6 @@ module.exports = {
// LMS // LMS
SingleSupportForm: './lms/static/support/jsx/single_support_form.jsx', SingleSupportForm: './lms/static/support/jsx/single_support_form.jsx',
AlertStatusBar: './lms/static/js/accessible_components/StatusBarAlert.jsx', AlertStatusBar: './lms/static/js/accessible_components/StatusBarAlert.jsx',
Bootstrap: './lms/static/common/js/vendor/bootstrap.js',
// Features // Features
CourseGoals: './openedx/features/course_experience/static/course_experience/js/CourseGoals.js', CourseGoals: './openedx/features/course_experience/static/course_experience/js/CourseGoals.js',
...@@ -62,8 +61,7 @@ module.exports = { ...@@ -62,8 +61,7 @@ module.exports = {
_: 'underscore', _: 'underscore',
$: 'jquery', $: 'jquery',
jQuery: 'jquery', jQuery: 'jquery',
'window.jQuery': 'jquery', 'window.jQuery': 'jquery'
Popper: ['popper.js', 'default']
}), }),
// Note: Until karma-webpack releases v3, it doesn't play well with // Note: Until karma-webpack releases v3, it doesn't play well with
......
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