fix(driver): remove pointless ATTACH_MODE config value

Removing `ATTACH_MODE` since as far as I can tell it's always `true`.

Signed-off-by: Jakub Sokołowski <jakub@status.im>
This commit is contained in:
Jakub Sokołowski 2023-11-30 11:23:50 +01:00
parent 81fe247d5a
commit 917a4bfde1
2 changed files with 10 additions and 21 deletions

View File

@ -19,7 +19,3 @@ if APP_DIR is None:
if system.IS_WIN and 'bin' not in APP_DIR: if system.IS_WIN and 'bin' not in APP_DIR:
exit('Please use launcher from "bin" folder in "APP_DIR"') exit('Please use launcher from "bin" folder in "APP_DIR"')
APP_DIR = SystemPath(APP_DIR) APP_DIR = SystemPath(APP_DIR)
# Application will be stuck in test execution if set to False (Mac only)
# We need to investigate more time on it.
ATTACH_MODE = True

View File

@ -100,7 +100,6 @@ class AUT:
self.options = options self.options = options
try: try:
self.port = local_system.find_free_port(configs.squish.AUT_PORT, 1000) self.port = local_system.find_free_port(configs.squish.AUT_PORT, 1000)
if configs.ATTACH_MODE:
SquishServer().add_attachable_aut(self.aut_id, self.port) SquishServer().add_attachable_aut(self.aut_id, self.port)
command = [ command = [
configs.testpath.SQUISH_DIR / 'bin' / 'startaut', configs.testpath.SQUISH_DIR / 'bin' / 'startaut',
@ -111,12 +110,6 @@ class AUT:
options options
] ]
self.pid = local_system.execute(command) self.pid = local_system.execute(command)
else:
SquishServer().add_executable_aut(self.aut_id, self.path.parent)
command = [self.aut_id, f'-d={self.app_data}']
self.ctx = squish.startApplication(' '.join(command), configs.timeouts.PROCESS_TIMEOUT_SEC)
self.pid = self.ctx.pid
self.attach() self.attach()
assert squish.waitFor(lambda: self.ctx.isRunning, configs.timeouts.PROCESS_TIMEOUT_SEC) assert squish.waitFor(lambda: self.ctx.isRunning, configs.timeouts.PROCESS_TIMEOUT_SEC)
return self return self