diff --git a/boffin/run_concurrently.py b/boffin/run_concurrently.py index 3632aae..65b2bb8 100644 --- a/boffin/run_concurrently.py +++ b/boffin/run_concurrently.py @@ -77,8 +77,7 @@ while clear_displays.poll() is None: sleep(1) # Generate the command for executing tests. -cmd = ("sudo su - thread%s; export DISPLAY=:%s; pybot -C off -K off -d " - args.reports_dir + "/%s; exit") +cmd = 'sudo su thread%s -c "export DISPLAY=:%s; pybot -C off -K off -d %s/%s"' if args.resources_dir: cmd += " -v resources_path:" + args.resources_dir + " " @@ -90,7 +89,7 @@ if args.tags_list and args.script_name: for i, tag in enumerate(args.tags_list): xvfb = Xvfb() xvfb.start() - values = (i, xvfb.vdisplay_num, i, tag) + values = (i, xvfb.vdisplay_num, args.reports_dir, i, tag) threads.append(Popen(cmd % values, shell=True)) while len(threads) == args.processes_count: wait_for_finished(threads)