Fixed indenting and cleaned up if clause

This commit is contained in:
JonahStanley
2013-07-30 12:46:42 -04:00
parent ee46b3ef24
commit dd0f7bc310
2 changed files with 2 additions and 2 deletions

View File

@@ -12,7 +12,7 @@ def create_component_instance(step, component_button_css, category,
has_multiple_templates=True):
click_new_component_button(step, component_button_css)
if category == 'problem' or category == 'html':
if category in ('problem', 'html'):
def animation_done(_driver):
return world.browser.evaluate_script("$('div.new-component').css('display')") == 'none'
world.wait_for(animation_done)

View File

@@ -157,7 +157,7 @@ def create_latex_problem(step):
world.click_new_component_button(step, '.large-problem-icon')
def animation_done(_driver):
return world.browser.evaluate_script("$('div.new-component').css('display')") == 'none'
return world.browser.evaluate_script("$('div.new-component').css('display')") == 'none'
world.wait_for(animation_done)
# Go to advanced tab.
world.css_click('#ui-id-2')