Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dotnet] Correct ChromiumDriverService.AllowedIPAddresses property name #13626

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
21 changes: 10 additions & 11 deletions dotnet/src/webdriver/Chromium/ChromiumDriverService.cs
Expand Up @@ -19,7 +19,6 @@
using System;
using System.Globalization;
using System.Text;
using OpenQA.Selenium.Internal;

namespace OpenQA.Selenium.Chromium
{
Expand All @@ -33,7 +32,7 @@ public abstract class ChromiumDriverService : DriverService
private string logPath = string.Empty;
private string urlPathPrefix = string.Empty;
private string portServerAddress = string.Empty;
private string allowedIpAddresses = string.Empty;
private string allowedIPAddresses = string.Empty;
private int adbPort = -1;
private bool disableBuildCheck;
private bool enableVerboseLogging;
Expand Down Expand Up @@ -122,22 +121,22 @@ public bool EnableAppendLog
/// connect to this instance of the Chrome driver. Defaults to an empty string,
/// which means only the local loopback address can connect.
/// </summary>
[Obsolete("Use AllowedIpAddresses")]
public string WhitelistedIpAddresses
[Obsolete($"Use {nameof(AllowedIPAddresses)}")]
public string WhitelistedIPAddresses
{
get { return this.allowedIpAddresses; }
set { this.allowedIpAddresses = value; }
get { return this.allowedIPAddresses; }
set { this.allowedIPAddresses = value; }
}

/// <summary>
/// Gets or sets the comma-delimited list of IP addresses that are approved to
/// connect to this instance of the Chrome driver. Defaults to an empty string,
/// which means only the local loopback address can connect.
/// </summary>
public string AllowedIpAddresses
public string AllowedIPAddresses
{
get { return this.allowedIpAddresses; }
set { this.allowedIpAddresses = value; }
get => this.allowedIPAddresses;
set => this.allowedIPAddresses = value;
}

/// <summary>
Expand Down Expand Up @@ -188,9 +187,9 @@ protected override string CommandLineArguments
argsBuilder.AppendFormat(CultureInfo.InvariantCulture, " --port-server={0}", this.portServerAddress);
}

if (!string.IsNullOrEmpty(this.allowedIpAddresses))
if (!string.IsNullOrEmpty(this.allowedIPAddresses))
{
argsBuilder.Append(string.Format(CultureInfo.InvariantCulture, " -allowed-ips={0}", this.allowedIpAddresses));
argsBuilder.Append(string.Format(CultureInfo.InvariantCulture, " -allowed-ips={0}", this.allowedIPAddresses));
}

return argsBuilder.ToString();
Expand Down