]> 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)
committerVladimir Panteleev <git@thecybershadow.net>
Wed, 13 Sep 2017 08:23:26 +0000 (08:23 +0000)
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 4046e620c5765240c0ece5e2548f888df94d5f5b..683f3d39bec3a82bf0ea0fc56ab5464a0fa9983b 100644 (file)
@@ -864,6 +864,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