Commit 76764b8b by JonahStanley

Fixed weight test so it won't behave differently on firefox

parent bcdc4bcb
...@@ -130,11 +130,7 @@ def set_the_weight_to_abc(step, bad_weight): ...@@ -130,11 +130,7 @@ def set_the_weight_to_abc(step, bad_weight):
world.verify_setting_entry(world.get_setting_entry(PROBLEM_WEIGHT), PROBLEM_WEIGHT, "", True) world.verify_setting_entry(world.get_setting_entry(PROBLEM_WEIGHT), PROBLEM_WEIGHT, "", True)
world.save_component_and_reopen(step) world.save_component_and_reopen(step)
# But no change was actually ever sent to the model, so on reopen, explicitly_set is False # But no change was actually ever sent to the model, so on reopen, explicitly_set is False
# On firefox with selenium, it will register as still being a change despite the weight remaining blank world.verify_setting_entry(world.get_setting_entry(PROBLEM_WEIGHT), PROBLEM_WEIGHT, "", False)
if world.is_firefox():
world.verify_setting_entry(world.get_setting_entry(PROBLEM_WEIGHT), PROBLEM_WEIGHT, "", True)
else:
world.verify_setting_entry(world.get_setting_entry(PROBLEM_WEIGHT), PROBLEM_WEIGHT, "", False)
@step('if I set the max attempts to "(.*)", it displays initially as "(.*)", and is persisted as "(.*)"') @step('if I set the max attempts to "(.*)", it displays initially as "(.*)", and is persisted as "(.*)"')
...@@ -228,7 +224,8 @@ def set_weight(weight): ...@@ -228,7 +224,8 @@ def set_weight(weight):
index = world.get_setting_entry_index(PROBLEM_WEIGHT) index = world.get_setting_entry_index(PROBLEM_WEIGHT)
world.css_fill('.wrapper-comp-setting .setting-input', weight, index=index) world.css_fill('.wrapper-comp-setting .setting-input', weight, index=index)
if world.is_firefox(): if world.is_firefox():
world.trigger_event('.wrapper-comp-setting .setting-input', index=index) world.trigger_event('.wrapper-comp-setting .setting-input', index=index, event='blur')
world.trigger_event('a.save-button', event='focus')
def open_high_level_source(): def open_high_level_source():
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment