Skip to content

Commit

Permalink
feat: remove disabled LaTex for ora mfe (#2160)
Browse files Browse the repository at this point in the history
* feat: remove disabled LaTex for ora mfe

* chore: remove LaTex test

* chore: version bump
  • Loading branch information
leangseu-edx authored Jan 16, 2024
1 parent dc53d20 commit 0c02eb0
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 22 deletions.
2 changes: 1 addition & 1 deletion openassessment/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
Initialization Information for Open Assessment Module
"""

__version__ = '6.0.26'
__version__ = '6.0.27'
6 changes: 0 additions & 6 deletions openassessment/xblock/openassessmentblock.py
Original file line number Diff line number Diff line change
Expand Up @@ -641,8 +641,6 @@ def mfe_views_supported(self):
Unsupported use-cases:
1) Team assignments
2) ORAs with leaderboards
3) ORAs with LaTeX previews enabled
4) Assignments with reordered assessment steps
Returns:
- False if we are in one of these unsupported configurations.
Expand All @@ -657,10 +655,6 @@ def mfe_views_supported(self):
if self.leaderboard_show != 0:
return False

# LaTeX previews not enabled yet
if self.allow_latex:
return False

return True

def ora_blocks_listing_view(self, context=None):
Expand Down
12 changes: 0 additions & 12 deletions openassessment/xblock/test/test_openassessment.py
Original file line number Diff line number Diff line change
Expand Up @@ -728,18 +728,6 @@ def test_mfe_views_supported__leaderboard(self, xblock, mock_value, expected_sup
# Then they are unsupported for ORAs with leaderboards
self.assertEqual(xblock.mfe_views_supported, expected_supported)

@ddt.unpack
@ddt.data((True, False), (False, True))
@patch.object(openassessmentblock.OpenAssessmentBlock, 'allow_latex', new_callable=PropertyMock)
@scenario('data/simple_self_staff_scenario.xml')
def test_mfe_views_supported__latex(self, xblock, mock_value, expected_supported, mock_allow_latex):
# Given I'm on / not on an ORA with a leaderboard
mock_allow_latex.return_value = mock_value

# When I see if MFE views are supported
# Then they are unsupported for ORAs with leaderboards
self.assertEqual(xblock.mfe_views_supported, expected_supported)

@scenario('data/assessment_steps_reordered.xml')
def test_mfe_views_supported__rearranged_steps(self, xblock):
# Given this ORA has rearranged our assessment steps
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "edx-ora2",
"version": "6.0.26",
"version": "6.0.27",
"repository": "https://github.com/openedx/edx-ora2.git",
"dependencies": {
"@edx/frontend-build": "8.0.6",
Expand Down

0 comments on commit 0c02eb0

Please sign in to comment.