Exemplo n.º 1
0
def test(data):
    actions.navigate(data.env.url + 'special-elements/')
    actions.assert_element_present('#double-click-one')
    golem_steps.assert_last_step_message('Assert element is present')
    with expected_exception(AssertionError,
                            'element #does-not-exist is not present'):
        actions.assert_element_present('#does-not-exist')
def test(data):
    actions.click(page_builder.code_button)
    page_builder_code.set_value('undefined_var')
    page_builder_code.save_page()
    actions.click(page_builder_code.preview_button)
    actions.assert_page_contains_text('There are errors in the page')
    actions.assert_page_contains_text('There are errors and the page cannot be displayed, '
                                      'open the page code editor to solve them.')
    actions.assert_element_present(page_builder.open_page_code_button)
Exemplo n.º 3
0
def test(data):
    test_builder.go_to_code_view()
    test_builder_code.set_value('undefined_var')
    test_builder_code.save_test()
    test_builder_code.go_to_preview_view()
    actions.assert_page_contains_text('There are errors in the test')
    actions.assert_page_contains_text(
        'There are errors and the test cannot be displayed, open the test code editor to solve them.'
    )
    actions.assert_element_present(test_builder.open_test_code_button)
Exemplo n.º 4
0
def test(data):
    actions.click(page_builder.code_button)
    actions.assert_element_present(page_builder_code.preview_button)
    actions.assert_url_contains('/code/')