Skip to content

Commit f121c7c

Browse files
--user
1 parent 728114f commit f121c7c

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/Microsoft.Android.Run/Program.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,8 @@ void OnCancelKeyPress (object? sender, ConsoleCancelEventArgs e)
194194
int RunInstrumentation ()
195195
{
196196
// Build the am instrument command
197-
var cmdArgs = $"shell am instrument -w {package}/{instrumentation}";
197+
var userArg = string.IsNullOrEmpty (deviceUserId) ? "" : $" --user {deviceUserId}";
198+
var cmdArgs = $"shell am instrument -w{userArg} {package}/{instrumentation}";
198199

199200
if (verbose)
200201
Console.WriteLine ($"Running instrumentation: adb {cmdArgs}");

0 commit comments

Comments
 (0)