Beispiel #1
0
def edit_component(index=0):
    # Verify that the "loading" indication has been hidden.
    world.wait_for_loading()
    # Verify that the "edit" button is present.
    world.wait_for(lambda _driver: world.css_visible('.edit-button'))
    world.css_click('.edit-button', index)
    world.wait_for_ajax_complete()
def edit_component(index=0):
    # Verify that the "loading" indication has been hidden.
    world.wait_for_loading()
    # Verify that the "edit" button is present.
    world.wait_for(lambda _driver: world.css_visible('a.edit-button'))
    world.css_click('a.edit-button', index)
    world.wait_for_ajax_complete()
Beispiel #3
0
def create_unit_from_course_outline():
    """
    Expands the section and clicks on the New Unit link.
    The end result is the page where the user is editing the new unit.
    """
    css_selectors = [
        '.outline-subsection .expand-collapse', '.outline-subsection .button-new'
    ]
    for selector in css_selectors:
        world.css_click(selector)

    world.wait_for_mathjax()
    world.wait_for_loading()

    assert world.is_css_present('ul.new-component-type')
Beispiel #4
0
def create_unit_from_course_outline():
    """
    Expands the section and clicks on the New Unit link.
    The end result is the page where the user is editing the new unit.
    """
    css_selectors = [
        '.outline-subsection .expand-collapse', '.outline-subsection .button-new'
    ]
    for selector in css_selectors:
        world.css_click(selector)

    world.wait_for_mathjax()
    world.wait_for_xmodule()
    world.wait_for_loading()

    assert world.is_css_present('ul.new-component-type')