Пример #1
0
def assert_policy_entries(expected_keys, expected_values):
    for key, value in zip(expected_keys, expected_values):
        index = get_index_of(key)
        assert_false(index == -1, "Could not find key: {key}".format(key=key))
        found_value = get_codemirror_value(index)
        assert_equal(
            value, found_value,
            "Expected {} to have value {} but found {}".format(key, value, found_value)
        )
def assert_policy_entries(expected_keys, expected_values):
    for key, value in zip(expected_keys, expected_values):
        index = get_index_of(key)
        assert_false(index == -1, "Could not find key: {key}".format(key=key))
        found_value = get_codemirror_value(index)
        assert_equal(
            value, found_value,
            "Expected {} to have value {} but found {}".format(
                key, value, found_value))
Пример #3
0
def verify_text_in_editor_and_update(button_css, before, after):
    world.css_click(button_css)
    text = get_codemirror_value()
    assert_in(before, text)
    change_text(after)
Пример #4
0
def get_display_name_value():
    index = get_index_of(DISPLAY_NAME_KEY)
    return get_codemirror_value(index)
def get_display_name_value():
    index = get_index_of(DISPLAY_NAME_KEY)
    return get_codemirror_value(index)
Пример #6
0
def check_raw_editor_text(step):
    assert_equal(step.multiline, get_codemirror_value(0))
Пример #7
0
def verify_code_editor_text(step, text):
    use_code_editor(
        lambda: assert_equal(text, get_codemirror_value(0, CODEMIRROR_SELECTOR_PREFIX))
    )
Пример #8
0
def verify_text_in_editor_and_update(button_css, before, after):
    world.css_click(button_css)
    text = get_codemirror_value()
    assert_in(before, text)
    change_text(after)
Пример #9
0
def verify_code_editor_text(_step, text):
    use_code_editor(lambda: assert_equal(
        text, get_codemirror_value(0, CODEMIRROR_SELECTOR_PREFIX)))
Пример #10
0
def check_raw_editor_text(step):
    assert_equal(step.multiline, get_codemirror_value(0))