Skip to content

Commit d825ba1

Browse files
authored
Merge branch 'trunk' into py_add_cdp_patch_rules
2 parents 2150d1c + f227da9 commit d825ba1

File tree

2 files changed

+15
-5
lines changed

2 files changed

+15
-5
lines changed

dotnet/src/webdriver/Safari/SafariDriverService.cs

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,7 @@
2020
using OpenQA.Selenium.Internal;
2121
using System;
2222
using System.IO;
23-
using System.Net;
24-
using System.Net.Http;
2523
using System.Text;
26-
using System.Threading.Tasks;
2724

2825
namespace OpenQA.Selenium.Safari;
2926

@@ -34,6 +31,13 @@ public sealed class SafariDriverService : DriverService
3431
{
3532
private const string DefaultSafariDriverServiceExecutableName = "safaridriver";
3633

34+
/// <summary>
35+
/// Enable diagnose logging.
36+
/// When set to <see langword="true"/>, the <b>SafariDriver</b> will be started with the <i>--diagnose</i> flag.
37+
/// Logs will be written to <i>~/Library/Logs/com.apple.WebDriver/</i>.
38+
/// </summary>
39+
public bool? Diagnose { get; set; }
40+
3741
/// <summary>
3842
/// Initializes a new instance of the <see cref="SafariDriverService"/> class.
3943
/// </summary>
@@ -59,6 +63,12 @@ protected override string CommandLineArguments
5963
get
6064
{
6165
StringBuilder argsBuilder = new StringBuilder(base.CommandLineArguments);
66+
67+
if (this.Diagnose is true)
68+
{
69+
argsBuilder.Append(" --diagnose");
70+
}
71+
6272
return argsBuilder.ToString();
6373
}
6474
}

java/src/org/openqa/selenium/remote/HttpCommandExecutor.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ public class HttpCommandExecutor implements CommandExecutor, NeedsLocalLogs {
4747

4848
private final URL remoteServer;
4949
public final HttpClient client;
50-
private final HttpClient.Factory httpClientFactory;
51-
private final Map<String, CommandInfo> additionalCommands;
50+
protected final HttpClient.Factory httpClientFactory;
51+
protected final Map<String, CommandInfo> additionalCommands;
5252
protected CommandCodec<HttpRequest> commandCodec;
5353
protected ResponseCodec<HttpResponse> responseCodec;
5454

0 commit comments

Comments
 (0)