Skip to content

Commit

Permalink
tests: wait a bit for the copy operation
Browse files Browse the repository at this point in the history
Zenity needs a bit of time to actually copy longer text. Wait a bit
before hitting ctrl+shift+c.
  • Loading branch information
marmarek committed Oct 25, 2024
1 parent b7d1e80 commit b4df77d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions qubes/tests/integ/basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -512,9 +512,10 @@ async def _test_clipboard(self, test_string,
# and xdotool will use XTEST instead of generating events manually -
# this will be much better - at least because events will have
# correct timestamp (so gui-daemon would not drop the copy request)
subprocess.check_call(['xdotool',
'key', 'ctrl+a', 'ctrl+c', 'ctrl+shift+c',
'Escape'])
subprocess.check_call(['xdotool', 'key', 'ctrl+a', 'ctrl+c'])
# wait a bit to let the zenity actually copy
await asyncio.sleep(1)
subprocess.check_call(['xdotool', 'key', 'ctrl+shift+c', 'Escape'])

await self.wait_for_window_coro(window_title, show=False)

Expand Down

0 comments on commit b4df77d

Please sign in to comment.