mirror of
https://github.com/teamcapybara/capybara.git
synced 2022-11-09 12:08:07 -05:00
Add auto height and width to the default make_visible CSS modifications
This commit is contained in:
parent
2309a12d2d
commit
63af1963b2
1 changed files with 3 additions and 1 deletions
|
@ -331,7 +331,9 @@ module Capybara
|
|||
end
|
||||
|
||||
def while_visible(element, visible_css)
|
||||
visible_css = { opacity: 1, display: 'block', visibility: 'visible' } if visible_css == true
|
||||
if visible_css == true
|
||||
visible_css = { opacity: 1, display: 'block', visibility: 'visible', width: 'auto', height: 'auto' }
|
||||
end
|
||||
_update_style(element, visible_css)
|
||||
raise ExpectationNotMet, 'The style changes in :make_visible did not make the file input visible' unless element.visible?
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue