From 9507b12fa1c684b3db4556940934ce6dc66fb623 Mon Sep 17 00:00:00 2001 From: Jesper Hodge Date: Fri, 17 Jan 2025 11:25:44 -0500 Subject: [PATCH] docs: improve how-to doc --- .../docs/how-tos/test_course_related_view_auth.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cms/djangoapps/contentstore/docs/how-tos/test_course_related_view_auth.rst b/cms/djangoapps/contentstore/docs/how-tos/test_course_related_view_auth.rst index 80b96b015242..b9b797ac436d 100644 --- a/cms/djangoapps/contentstore/docs/how-tos/test_course_related_view_auth.rst +++ b/cms/djangoapps/contentstore/docs/how-tos/test_course_related_view_auth.rst @@ -13,6 +13,10 @@ be tested for the following. How to test ----------- +The `AuthorizeStaffTestCase` class provides a set of tests that can be used to test the authorization +of a view. If you inherit from this class, these tests will be automatically run. For details, +please look at the source code of the `AuthorizeStaffTestCase` class. + A lot of these tests can be easily implemented by inheriting from the `AuthorizeStaffTestCase`. This parent class assumes that the view is for a specific course and that only users who have access to the course can access the view. (They are either staff or instructors for the course, or global admin).