]> git.sur5r.net Git - i3/i3/commitdiff
testcases/lib: Add inject_randr15_outputinfo argument
authorVladimir Panteleev <git@thecybershadow.net>
Tue, 12 Sep 2017 08:41:00 +0000 (08:41 +0000)
committerMichael Stapelberg <michael@stapelberg.de>
Wed, 13 Sep 2017 16:45:46 +0000 (18:45 +0200)
Allow tests to specify a file name for inject_randr15's
--getoutputinfo_reply command-line parameter.

testcases/lib/SocketActivation.pm
testcases/lib/i3test.pm.in

index 0f307eb3366abc04c230f068ee050fd9347d6a70..5951fd2663c6bb9e415db13750da670a346af132 100644 (file)
@@ -145,7 +145,12 @@ sub activate_i3 {
         if ($args{inject_randr15}) {
             # See comment in $args{strace} branch.
             $cmd = 'test.inject_randr15 --getmonitors_reply="' .
-                   $args{inject_randr15} . '" -- ' .
+                   $args{inject_randr15} . '" ' .
+                   ($args{inject_randr15_outputinfo}
+                    ? '--getoutputinfo_reply="' .
+                      $args{inject_randr15_outputinfo} . '" '
+                    : '') .
+                   '-- ' .
                    'sh -c "export LISTEN_PID=\$\$; ' . $cmd . '"';
         }
 
index 18bebb52146ed0dba8e2471d565c1a1118f9520f..f9b3e9398e4165e35edb1d4ee7cc2dd8776ecfae 100644 (file)
@@ -863,6 +863,7 @@ sub launch_with_config {
         dont_create_temp_dir => $args{dont_create_temp_dir},
         validate_config => $args{validate_config},
         inject_randr15 => $args{inject_randr15},
+        inject_randr15_outputinfo => $args{inject_randr15_outputinfo},
     );
 
     # If we called i3 with -C, we wait for it to exit and then return as