From: Vladimir Panteleev Date: Tue, 12 Sep 2017 08:41:00 +0000 (+0000) Subject: testcases/lib: Add inject_randr15_outputinfo argument X-Git-Tag: 4.14.1~43 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=21dd8c475aec6c52898f4fe9b15dc4fa026089f8;p=i3%2Fi3 testcases/lib: Add inject_randr15_outputinfo argument Allow tests to specify a file name for inject_randr15's --getoutputinfo_reply command-line parameter. --- diff --git a/testcases/lib/SocketActivation.pm b/testcases/lib/SocketActivation.pm index 0f307eb3..5951fd26 100644 --- a/testcases/lib/SocketActivation.pm +++ b/testcases/lib/SocketActivation.pm @@ -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 . '"'; } diff --git a/testcases/lib/i3test.pm.in b/testcases/lib/i3test.pm.in index 18bebb52..f9b3e939 100644 --- a/testcases/lib/i3test.pm.in +++ b/testcases/lib/i3test.pm.in @@ -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