2019-07-25 05:27:42 +00:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2017-09-19 13:01:01 +00:00
|
|
|
module BoardHelpers
|
|
|
|
def click_card(card)
|
|
|
|
within card do
|
2018-04-13 20:27:10 +00:00
|
|
|
first('.board-card-number').click
|
2017-09-19 13:01:01 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
wait_for_sidebar
|
|
|
|
end
|
|
|
|
|
|
|
|
def wait_for_sidebar
|
|
|
|
# loop until the CSS transition is complete
|
|
|
|
Timeout.timeout(0.5) do
|
|
|
|
loop until evaluate_script('$(".right-sidebar").outerWidth()') == 290
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|