* Generate common/djangoapps import shims for LMS
* Generate common/djangoapps import shims for Studio
* Stop appending project root to sys.path
* Stop appending common/djangoapps to sys.path
* Import from common.djangoapps.course_action_state instead of course_action_state
* Import from common.djangoapps.course_modes instead of course_modes
* Import from common.djangoapps.database_fixups instead of database_fixups
* Import from common.djangoapps.edxmako instead of edxmako
* Import from common.djangoapps.entitlements instead of entitlements
* Import from common.djangoapps.pipline_mako instead of pipeline_mako
* Import from common.djangoapps.static_replace instead of static_replace
* Import from common.djangoapps.student instead of student
* Import from common.djangoapps.terrain instead of terrain
* Import from common.djangoapps.third_party_auth instead of third_party_auth
* Import from common.djangoapps.track instead of track
* Import from common.djangoapps.util instead of util
* Import from common.djangoapps.xblock_django instead of xblock_django
* Add empty common/djangoapps/__init__.py to fix pytest collection
* Fix pylint formatting violations
* Exclude import_shims/ directory tree from linting
* updated files according to INCR-265
* fixed docstring and line-length problems from quality test
* Revert "fixed docstring and line-length problems from quality test"
This reverts commit d050f55a4ecfaa38f46b80ec4bb85ff399a79a8c.
* fixed errors reported in quality report
* had error, fixed it
* reversed change
* fixed over/under indentation, and added line to import.py that Ned had suggested
* tried disabling pylint for this line
* testing new email
* testing email in different window
* re-added symlink and docstring
- Certificates management commands updates
- Moving reverse calls in tests into setUp from class definition
- Import shuffling
- Consolidating cryptograhpy version to 1.9
This modifies the lang-pref django app to:
a) Use the current value of the 'edx-language-preference' cookie to set the
users Accept-Language header on an incoming request.
b) At the end of the request, update the 'edx-language-preference' cookie
to reflect the users current Language Preference choice, if any.
[LEARNER-542]
Remove the DarkLang middleware from the LMS
Created and basic routing to the update_lang page for the GET Request
TNL-4742
Basic form functionality
Working example in LMS of the form to set the language
Login now required to change the preview language, and corrected some minor bugs
Updates to move the template code to lms and to correct minor defects
TNL-4742
Added template for preview_lang.html to cms
TNL-4742
Changed filename of darklang.py to api.py to match convention
TNL-4742
Updated and refactored the Darklang tests
TNL-4742
Updated comments in tests
TNL-4742
Formating updates
TNL-4742
Updated comments and formatting
TNL-4742
Corrected i18n tests and corrected PEP8 format issues
TNL-4742
Code Lint/PEP-8 corrections and upates
TNL-4742
Removed constant that was not needed (to be squashed)
TNL-4742
Added init method to clear up PEP8 Warnings (will squash)
TNL-4742
PEP-8/Lint issue resolved (squash)
Updated for i18n
TNL-4742
Refactored the preview_lang.html page to use a common included template
Refactoring and changes from PR comments
TNL-4742
Correction for safecommit violation (Squash)
TNL-4742
PR changes and refactoring (Squash)
Updates to reduce changes made in the urls used
TNL-4742
Removed unneeded aria-described by and bug in MAKO Template (squash)
TNK-4742
Updated docstring comments
Clarified form response text
Minor PR request (Squash)
Refactoring of how the responses are generated within the DarkLang views file
A series of refactors in response to PR comments
Method name change for clarity in reponse to PR comments (Squash)
Updates to tests per PR requests (Squash)
Minor comment updates for clarity and PR requests (Squash)
Updated per PR comments and added a test for empty preview_language
Layout and code style updates (Squash)
Updated test to contain method in the request.
Removed the Darklang preview-lang and clear-lang parameters and added the new DarkLang settings form at /update_lang
Refactored tests and added some tests for coverage, corrected defect with empty input codes
Removed unused and obsolete code
Corrected test errors, resolved PR comments, and updated comments to clarify testing
TNL-4742
Updated tests to deal with Pylint quality issue (Squash)
Updated tests to better reflect test case and PR updates (Squash)
This abstract class contains most of the fields (aside from the id and
foreign key to StudentModule that the subclasses need to manage). It
also provides a get_history method that abstracts searching across
multiple backends.
Move router code to openedx/core
We need to use it from cms and lms.
Ensure aws_migrate can be used for migrating both the lms and cms.
Handle queries directed to student_module_history vs default and the
extra queries generated by Django 1.8 (SAVEPOINTS, etc).
Additionally, flag testing classes as multi_db so that Django will
flush the non-default database between unit tests.
Further decouple the foreignkey relation between csm and csmhe
When calling StudentModule().delete() Django will try to delete CSMHE
objects, but naively does so in the database, not by consulting the
database router.
Instead, we disable django cascading deletes and listen for post_delete
signals and clean up CSMHE by hand.
Add feature flags for CSMHE
One to turn it on/off so we can control the deploy.
The other will control whether or not we read from two database tables
or one when searching.
Update tests to explicitly use this get_history method rather than
looking directly into StudentModuleHistory or
StudentModuleHistoryExtended.
Inform lettuce to avoid the coursewarehistoryextended app
Otherwise it fails when it can't find features/ in that app.
Add Pg support, this is not tested automatically.
The existing pattern of using `override_settings(MODULESTORE=...)` prevented
us from having more than one layer of subclassing in modulestore tests.
In a structure like:
@override_settings(MODULESTORE=store_a)
class BaseTestCase(ModuleStoreTestCase):
def setUp(self):
# use store
@override_settings(MODULESTORE=store_b)
class ChildTestCase(BaseTestCase):
def setUp(self):
# use store
In this case, the store actions performed in `BaseTestCase` on behalf of
`ChildTestCase` would still use `store_a`, even though the `ChildTestCase`
had specified to use `store_b`. This is because the `override_settings`
decorator would be the innermost wrapper around the `BaseTestCase.setUp` method,
no matter what `ChildTestCase` does.
To remedy this, we move the call to `override_settings` into the
`ModuleStoreTestCase.setUp` method, and use a cleanup to remove the override.
Subclasses can just defined the `MODULESTORE` class attribute to specify which
modulestore to use _for the entire `setUp` chain_.
[PLAT-419]
Move modulestore config for tests to an importable location
Disable pylnt warning for lms imports in common tests
Refactor all testcases that loaded all xml courses
TE-610
TE-489