Commit 4a1bc538 by Jesse Zoldak

Wait for the transcript file chooser input field to be visible

parent 545c9cbb
......@@ -639,6 +639,8 @@ class VideoComponentPage(VideoPage):
# Show the Browse Button
self.browser.execute_script("$('form.file-chooser').show()")
asset_file_path = self.file_path(transcript_filename)
self.q(css=CLASS_SELECTORS['attach_transcript']).results[0].send_keys(asset_file_path)
attach_css = CLASS_SELECTORS['attach_transcript']
self.wait_for_element_visibility(attach_css, "The file chooser's input field is visible.")
self.q(css=attach_css).results[0].send_keys(asset_file_path)
# confirm upload completion
self._wait_for(lambda: not self.q(css=CLASS_SELECTORS['attach_transcript']).visible, 'Upload Completed')
self._wait_for(lambda: not self.q(css=attach_css).visible, 'Upload Completed')
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