コード例 #1
0
class ToolsImportHelpTest(StudioCourseTest):
    """
    Tests help links on tools import pages.
    """
    def setUp(self, is_staff=False, test_xss=True):

        super(ToolsImportHelpTest, self).setUp()

        self.import_page = ImportCoursePage(self.browser,
                                            self.course_info['org'],
                                            self.course_info['number'],
                                            self.course_info['run'])
        self.import_page.visit()

    @skip(
        "Disabled as edx.org help links are now different than Open edX (@catong can advise)"
    )
    def test_tools_import_nav_help(self):
        """
        Scenario: Help link in navigation bar is working on tools Library import page
        Given that I am on the Library import tools page
        And I want help about the process
        And I click the 'Help' in the navigation bar
        Then Help link should open.
        And help url should be correct
        """
        expected_url = _get_expected_documentation_url(
            '/releasing_course/export_import_course.html#import-a-course')

        # Assert that help link is correct.
        assert_nav_help_link(
            test=self,
            page=self.import_page,
            href=expected_url,
        )

    @skip(
        "Disabled as edx.org help links are now different than Open edX (@catong can advise)"
    )
    def test_tools_import_side_bar_help(self):
        """
        Scenario: Help link in side bar is working on tools Library import page
        Given that I am on the tools Library import page
        And I want help about the process
        And I click the 'Learn more about importing a course' in the sidebar links
        Then Help link should open.
        And help url should be correct
        """
        expected_url = _get_expected_documentation_url(
            '/releasing_course/export_import_course.html#import-a-course')

        # Assert that help link is correct.
        assert_side_bar_help_link(
            test=self,
            page=self.import_page,
            href=expected_url,
            help_text='Learn more about importing a course',
        )
コード例 #2
0
    def setUp(self, is_staff=False, test_xss=True):

        super(ToolsImportHelpTest, self).setUp()

        self.import_page = ImportCoursePage(self.browser,
                                            self.course_info['org'],
                                            self.course_info['number'],
                                            self.course_info['run'])
        self.import_page.visit()
コード例 #3
0
class ToolsImportHelpTest(StudioCourseTest):
    """
    Tests help links on tools import pages.
    """
    def setUp(self, is_staff=False, test_xss=True):

        super(ToolsImportHelpTest, self).setUp()

        self.import_page = ImportCoursePage(
            self.browser,
            self.course_info['org'],
            self.course_info['number'],
            self.course_info['run']
        )
        self.import_page.visit()

    def test_tools_import_nav_help(self):
        """
        Scenario: Help link in navigation bar is working on tools Library import page
        Given that I am on the Library import tools page
        And I want help about the process
        And I click the 'Help' in the navigation bar
        Then Help link should open.
        And help url should end with 'releasing_course/export_import_course.html#import-a-course'
        """
        href = 'http://edx.readthedocs.io/projects/open-edx-building-and-running-a-course/en/' \
               'open-release-ficus.master/releasing_course/export_import_course.html#import-a-course'

        # Assert that help link is correct.
        assert_nav_help_link(
            test=self,
            page=self.import_page,
            href=href
        )

    def test_tools_import_side_bar_help(self):
        """
        Scenario: Help link in side bar is working on tools Library import page
        Given that I am on the tools Library import page
        And I want help about the process
        And I click the 'Learn more about importing a course' in the sidebar links
        Then Help link should open.
        And help url should end with 'releasing_course/export_import_course.html#import-a-course'
        """
        href = 'http://edx.readthedocs.io/projects/open-edx-building-and-running-a-course/en/' \
               'open-release-ficus.master/releasing_course/export_import_course.html#import-a-course'

        # Assert that help link is correct.
        assert_side_bar_help_link(
            test=self,
            page=self.import_page,
            href=href,
            help_text='Learn more about importing a course',
        )
コード例 #4
0
class ToolsImportHelpTest(StudioCourseTest):
    """
    Tests help links on tools import pages.
    """
    def setUp(self, is_staff=False, test_xss=True):

        super(ToolsImportHelpTest, self).setUp()

        self.import_page = ImportCoursePage(
            self.browser,
            self.course_info['org'],
            self.course_info['number'],
            self.course_info['run']
        )
        self.import_page.visit()

    def test_tools_import_nav_help(self):
        """
        Scenario: Help link in navigation bar is working on tools Library import page
        Given that I am on the Library import tools page
        And I want help about the process
        And I click the 'Help' in the navigation bar
        Then Help link should open.
        And help url should be correct
        """
        expected_url = _get_expected_documentation_url('/releasing_course/export_import_course.html#import-a-course')

        # Assert that help link is correct.
        assert_nav_help_link(
            test=self,
            page=self.import_page,
            href=expected_url,
        )

    def test_tools_import_side_bar_help(self):
        """
        Scenario: Help link in side bar is working on tools Library import page
        Given that I am on the tools Library import page
        And I want help about the process
        And I click the 'Learn more about importing a course' in the sidebar links
        Then Help link should open.
        And help url should be correct
        """
        expected_url = _get_expected_documentation_url('/releasing_course/export_import_course.html#import-a-course')

        # Assert that help link is correct.
        assert_side_bar_help_link(
            test=self,
            page=self.import_page,
            href=expected_url,
            help_text='Learn more about importing a course',
        )
コード例 #5
0
class ToolsImportHelpTest(StudioCourseTest):
    """
    Tests help links on tools import pages.
    """
    def setUp(self, is_staff=False, test_xss=True):

        super(ToolsImportHelpTest, self).setUp()

        self.import_page = ImportCoursePage(self.browser,
                                            self.course_info['org'],
                                            self.course_info['number'],
                                            self.course_info['run'])
        self.import_page.visit()

    def test_tools_import_nav_help(self):
        """
        Scenario: Help link in navigation bar is working on tools Library import page
        Given that I am on the Library import tools page
        And I want help about the process
        And I click the 'Help' in the navigation bar
        Then Help link should open.
        And help url should end with 'releasing_course/export_import_course.html#import-a-course'
        """
        href = 'http://edx.readthedocs.io/projects/open-edx-building-and-running-a-course/en/' \
               'latest/releasing_course/export_import_course.html#import-a-course'

        # Assert that help link is correct.
        assert_nav_help_link(test=self, page=self.import_page, href=href)

    def test_tools_import_side_bar_help(self):
        """
        Scenario: Help link in side bar is working on tools Library import page
        Given that I am on the tools Library import page
        And I want help about the process
        And I click the 'Learn more about importing a course' in the sidebar links
        Then Help link should open.
        And help url should end with 'releasing_course/export_import_course.html#import-a-course'
        """
        href = 'http://edx.readthedocs.io/projects/open-edx-building-and-running-a-course/en/' \
               'latest/releasing_course/export_import_course.html#import-a-course'

        # Assert that help link is correct.
        assert_side_bar_help_link(
            test=self,
            page=self.import_page,
            href=href,
            help_text='Learn more about importing a course',
        )
コード例 #6
0
    def setUp(self, is_staff=False, test_xss=True):

        super(ToolsImportHelpTest, self).setUp()

        self.import_page = ImportCoursePage(
            self.browser, self.course_info["org"], self.course_info["number"], self.course_info["run"]
        )
        self.import_page.visit()