tests: fix deadlock in filecopy test
Error window (where test need to send Enter key) is opened while qvm-move-to-vm is still running.
This commit is contained in:
		
							parent
							
								
									99874a0a25
								
							
						
					
					
						commit
						19a1579a99
					
				| @ -704,13 +704,17 @@ class TC_00_AppVMMixin(object): | |||||||
|             user='root')) |             user='root')) | ||||||
| 
 | 
 | ||||||
|         with self.qrexec_policy('qubes.Filecopy', self.testvm1, self.testvm2): |         with self.qrexec_policy('qubes.Filecopy', self.testvm1, self.testvm2): | ||||||
|             with self.assertRaises(subprocess.CalledProcessError): |             p = self.loop.run_until_complete(self.testvm1.run( | ||||||
|                 self.loop.run_until_complete(self.testvm1.run_for_stdio( |  | ||||||
|                 'qvm-move-to-vm {} /tmp/testfile'.format( |                 'qvm-move-to-vm {} /tmp/testfile'.format( | ||||||
|                     self.testvm2.name))) |                     self.testvm2.name))) | ||||||
| 
 | 
 | ||||||
|             # Close GUI error message |             # Close GUI error message | ||||||
|  |             try: | ||||||
|                 self.enter_keys_in_window('Error', ['Return']) |                 self.enter_keys_in_window('Error', ['Return']) | ||||||
|  |             except subprocess.CalledProcessError: | ||||||
|  |                 pass | ||||||
|  |             self.loop.run_until_complete(p.wait()) | ||||||
|  |             self.assertNotEqual(p.returncode, 0) | ||||||
| 
 | 
 | ||||||
|         # the file shouldn't be removed in source vm |         # the file shouldn't be removed in source vm | ||||||
|         self.loop.run_until_complete(self.testvm1.run_for_stdio( |         self.loop.run_until_complete(self.testvm1.run_for_stdio( | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Marek Marczykowski-Górecki
						Marek Marczykowski-Górecki