Skip to content

Commit d6bb232

Browse files
committed
[dotnet] Update supported version of CDP to 93, remove 91
1 parent 618e8aa commit d6bb232

12 files changed

+60
-57
lines changed

dotnet/CHANGELOG

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
v4.0.0rc1
22
=========
3-
* Set available versions of Chrome DevTools Protocol to 85, 91, and 92.
3+
* Set available versions of Chrome DevTools Protocol to 85, 92, and 93.
44
* Enabled script pinning. This allows the user to add a snippet of JavaScript
55
to a page that will be available on all subsquent pages, and not have to
66
pass the script across the wire every time. For exceptionally large blobs

dotnet/selenium-dotnet-version.bzl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ SUPPORTED_NET_STANDARD_VERSIONS = ["netstandard2.0", "netstandard2.1", "net5.0"]
77

88
SUPPORTED_DEVTOOLS_VERSIONS = [
99
"v85",
10-
"v91",
1110
"v92",
11+
"v93",
1212
]
1313

1414
ASSEMBLY_COMPANY = "Selenium Committers"

dotnet/src/webdriver/DevTools/DevToolsDomains.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ public abstract class DevToolsDomains
3737
// added to this dictionary.
3838
private static readonly Dictionary<int, Type> SupportedDevToolsVersions = new Dictionary<int, Type>()
3939
{
40+
{ 93, typeof(V93.V93Domains) },
4041
{ 92, typeof(V92.V92Domains) },
41-
{ 91, typeof(V91.V91Domains) },
4242
{ 85, typeof(V85.V85Domains) }
4343
};
4444

dotnet/src/webdriver/DevTools/v91/V91Domains.cs renamed to dotnet/src/webdriver/DevTools/v93/V93Domains.cs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// <copyright file="V91Domains.cs" company="WebDriver Committers">
1+
// <copyright file="V93Domains.cs" company="WebDriver Committers">
22
// Licensed to the Software Freedom Conservancy (SFC) under one
33
// or more contributor license agreements. See the NOTICE file
44
// distributed with this work for additional information
@@ -19,16 +19,16 @@
1919
using System.Collections.Generic;
2020
using System.Text;
2121

22-
namespace OpenQA.Selenium.DevTools.V91
22+
namespace OpenQA.Selenium.DevTools.V93
2323
{
2424
/// <summary>
2525
/// Class containing the domain implementation for version 90 of the DevTools Protocol.
2626
/// </summary>
27-
public class V91Domains : DevToolsDomains
27+
public class V93Domains : DevToolsDomains
2828
{
2929
private DevToolsSessionDomains domains;
3030

31-
public V91Domains(DevToolsSession session)
31+
public V93Domains(DevToolsSession session)
3232
{
3333
this.domains = new DevToolsSessionDomains(session);
3434
}
@@ -46,21 +46,21 @@ public V91Domains(DevToolsSession session)
4646
/// <summary>
4747
/// Gets the object used for manipulating network information in the browser.
4848
/// </summary>
49-
public override DevTools.Network Network => new V91Network(domains.Network, domains.Fetch);
49+
public override DevTools.Network Network => new V93Network(domains.Network, domains.Fetch);
5050

5151
/// <summary>
5252
/// Gets the object used for manipulating the browser's JavaScript execution.
5353
/// </summary>
54-
public override JavaScript JavaScript => new V91JavaScript(domains.Runtime, domains.Page);
54+
public override JavaScript JavaScript => new V93JavaScript(domains.Runtime, domains.Page);
5555

5656
/// <summary>
5757
/// Gets the object used for manipulating DevTools Protocol targets.
5858
/// </summary>
59-
public override DevTools.Target Target => new V91Target(domains.Target);
59+
public override DevTools.Target Target => new V93Target(domains.Target);
6060

6161
/// <summary>
6262
/// Gets the object used for manipulating the browser's logs.
6363
/// </summary>
64-
public override DevTools.Log Log => new V91Log(domains.Log);
64+
public override DevTools.Log Log => new V93Log(domains.Log);
6565
}
6666
}

dotnet/src/webdriver/DevTools/v91/V91JavaScript.cs renamed to dotnet/src/webdriver/DevTools/v93/V93JavaScript.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// <copyright file="V91JavaScript.cs" company="WebDriver Committers">
1+
// <copyright file="V93JavaScript.cs" company="WebDriver Committers">
22
// Licensed to the Software Freedom Conservancy (SFC) under one
33
// or more contributor license agreements. See the NOTICE file
44
// distributed with this work for additional information
@@ -18,25 +18,25 @@
1818
using System;
1919
using System.Collections.Generic;
2020
using System.Threading.Tasks;
21-
using OpenQA.Selenium.DevTools.V91.Page;
22-
using OpenQA.Selenium.DevTools.V91.Runtime;
21+
using OpenQA.Selenium.DevTools.V93.Page;
22+
using OpenQA.Selenium.DevTools.V93.Runtime;
2323

24-
namespace OpenQA.Selenium.DevTools.V91
24+
namespace OpenQA.Selenium.DevTools.V93
2525
{
2626
/// <summary>
2727
/// Class containing the JavaScript implementation for version 89 of the DevTools Protocol.
2828
/// </summary>
29-
public class V91JavaScript : JavaScript
29+
public class V93JavaScript : JavaScript
3030
{
3131
private RuntimeAdapter runtime;
3232
private PageAdapter page;
3333

3434
/// <summary>
35-
/// Initializes a new instance of the <see cref="V91JavaScript"/> class.
35+
/// Initializes a new instance of the <see cref="V93JavaScript"/> class.
3636
/// </summary>
3737
/// <param name="runtime">The DevTools Protocol adapter for the Runtime domain.</param>
3838
/// <param name="page">The DevTools Protocol adapter for the Page domain.</param>
39-
public V91JavaScript(RuntimeAdapter runtime, PageAdapter page)
39+
public V93JavaScript(RuntimeAdapter runtime, PageAdapter page)
4040
{
4141
this.runtime = runtime;
4242
this.page = page;

dotnet/src/webdriver/DevTools/v91/V91Log.cs renamed to dotnet/src/webdriver/DevTools/v93/V93Log.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// <copyright file="V91Log.cs" company="WebDriver Committers">
1+
// <copyright file="V93Log.cs" company="WebDriver Committers">
22
// Licensed to the Software Freedom Conservancy (SFC) under one
33
// or more contributor license agreements. See the NOTICE file
44
// distributed with this work for additional information
@@ -20,22 +20,22 @@
2020
using System.Text;
2121
using System.Threading;
2222
using System.Threading.Tasks;
23-
using OpenQA.Selenium.DevTools.V91.Log;
23+
using OpenQA.Selenium.DevTools.V93.Log;
2424

25-
namespace OpenQA.Selenium.DevTools.V91
25+
namespace OpenQA.Selenium.DevTools.V93
2626
{
2727
/// <summary>
2828
/// Class containing the browser's log as referenced by version 89 of the DevTools Protocol.
2929
/// </summary>
30-
public class V91Log : DevTools.Log
30+
public class V93Log : DevTools.Log
3131
{
3232
private LogAdapter adapter;
3333

3434
/// <summary>
35-
/// Initializes a new instance of the <see cref="V91Log"/> class.
35+
/// Initializes a new instance of the <see cref="V93Log"/> class.
3636
/// </summary>
3737
/// <param name="adapter">The adapter for the Log domain.</param>
38-
public V91Log(LogAdapter adapter)
38+
public V93Log(LogAdapter adapter)
3939
{
4040
this.adapter = adapter;
4141
this.adapter.EntryAdded += OnAdapterEntryAdded;

dotnet/src/webdriver/DevTools/v91/V91Network.cs renamed to dotnet/src/webdriver/DevTools/v93/V93Network.cs

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// <copyright file="V91Network.cs" company="WebDriver Committers">
1+
// <copyright file="V93Network.cs" company="WebDriver Committers">
22
// Licensed to the Software Freedom Conservancy (SFC) under one
33
// or more contributor license agreements. See the NOTICE file
44
// distributed with this work for additional information
@@ -20,25 +20,25 @@
2020
using System.Collections.Generic;
2121
using System.Text;
2222
using System.Threading.Tasks;
23-
using OpenQA.Selenium.DevTools.V91.Fetch;
24-
using OpenQA.Selenium.DevTools.V91.Network;
23+
using OpenQA.Selenium.DevTools.V93.Fetch;
24+
using OpenQA.Selenium.DevTools.V93.Network;
2525

26-
namespace OpenQA.Selenium.DevTools.V91
26+
namespace OpenQA.Selenium.DevTools.V93
2727
{
2828
/// <summary>
2929
/// Class providing functionality for manipulating network calls using version 89 of the DevTools Protocol
3030
/// </summary>
31-
public class V91Network : DevTools.Network
31+
public class V93Network : DevTools.Network
3232
{
3333
private FetchAdapter fetch;
3434
private NetworkAdapter network;
3535

3636
/// <summary>
37-
/// Initializes a new instance of the <see cref="V91Network"/> class.
37+
/// Initializes a new instance of the <see cref="V93Network"/> class.
3838
/// </summary>
3939
/// <param name="network">The adapter for the Network domain.</param>
4040
/// <param name="fetch">The adapter for the Fetch domain.</param>
41-
public V91Network(NetworkAdapter network, FetchAdapter fetch)
41+
public V93Network(NetworkAdapter network, FetchAdapter fetch)
4242
{
4343
this.network = network;
4444
this.fetch = fetch;
@@ -80,12 +80,12 @@ public override async Task DisableNetwork()
8080
/// <returns>A task that represents the asynchronous operation.</returns>
8181
public override async Task EnableFetchForAllPatterns()
8282
{
83-
await fetch.Enable(new OpenQA.Selenium.DevTools.V91.Fetch.EnableCommandSettings()
83+
await fetch.Enable(new OpenQA.Selenium.DevTools.V93.Fetch.EnableCommandSettings()
8484
{
85-
Patterns = new OpenQA.Selenium.DevTools.V91.Fetch.RequestPattern[]
85+
Patterns = new OpenQA.Selenium.DevTools.V93.Fetch.RequestPattern[]
8686
{
87-
new OpenQA.Selenium.DevTools.V91.Fetch.RequestPattern() { UrlPattern = "*", RequestStage = RequestStage.Request },
88-
new OpenQA.Selenium.DevTools.V91.Fetch.RequestPattern() { UrlPattern = "*", RequestStage = RequestStage.Response }
87+
new OpenQA.Selenium.DevTools.V93.Fetch.RequestPattern() { UrlPattern = "*", RequestStage = RequestStage.Request },
88+
new OpenQA.Selenium.DevTools.V93.Fetch.RequestPattern() { UrlPattern = "*", RequestStage = RequestStage.Response }
8989
},
9090
HandleAuthRequests = true
9191
});
@@ -193,9 +193,9 @@ public override async Task ContinueWithAuth(string requestId, string userName, s
193193
await fetch.ContinueWithAuth(new ContinueWithAuthCommandSettings()
194194
{
195195
RequestId = requestId,
196-
AuthChallengeResponse = new V91.Fetch.AuthChallengeResponse()
196+
AuthChallengeResponse = new V93.Fetch.AuthChallengeResponse()
197197
{
198-
Response = V91.Fetch.AuthChallengeResponseResponseValues.ProvideCredentials,
198+
Response = V93.Fetch.AuthChallengeResponseResponseValues.ProvideCredentials,
199199
Username = userName,
200200
Password = password
201201
}
@@ -212,9 +212,9 @@ public override async Task CancelAuth(string requestId)
212212
await fetch.ContinueWithAuth(new ContinueWithAuthCommandSettings()
213213
{
214214
RequestId = requestId,
215-
AuthChallengeResponse = new OpenQA.Selenium.DevTools.V91.Fetch.AuthChallengeResponse()
215+
AuthChallengeResponse = new OpenQA.Selenium.DevTools.V93.Fetch.AuthChallengeResponse()
216216
{
217-
Response = V91.Fetch.AuthChallengeResponseResponseValues.CancelAuth
217+
Response = V93.Fetch.AuthChallengeResponseResponseValues.CancelAuth
218218
}
219219
});
220220
}

dotnet/src/webdriver/DevTools/v91/V91Target.cs renamed to dotnet/src/webdriver/DevTools/v93/V93Target.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// <copyright file="V91Target.cs" company="WebDriver Committers">
1+
// <copyright file="V93Target.cs" company="WebDriver Committers">
22
// Licensed to the Software Freedom Conservancy (SFC) under one
33
// or more contributor license agreements. See the NOTICE file
44
// distributed with this work for additional information
@@ -21,22 +21,22 @@
2121
using System.Collections.ObjectModel;
2222
using System.Text;
2323
using System.Threading.Tasks;
24-
using OpenQA.Selenium.DevTools.V91.Target;
24+
using OpenQA.Selenium.DevTools.V93.Target;
2525

26-
namespace OpenQA.Selenium.DevTools.V91
26+
namespace OpenQA.Selenium.DevTools.V93
2727
{
2828
/// <summary>
2929
/// Class providing functionality for manipulating targets for version 89 of the DevTools Protocol
3030
/// </summary>
31-
public class V91Target : DevTools.Target
31+
public class V93Target : DevTools.Target
3232
{
3333
private TargetAdapter adapter;
3434

3535
/// <summary>
36-
/// Initializes a new instance of the <see cref="V91Target"/> class.
36+
/// Initializes a new instance of the <see cref="V93Target"/> class.
3737
/// </summary>
3838
/// <param name="adapter">The adapter for the Target domain.</param>
39-
public V91Target(TargetAdapter adapter)
39+
public V93Target(TargetAdapter adapter)
4040
{
4141
this.adapter = adapter;
4242
}

dotnet/src/webdriver/Remote/DriverServiceCommandExecutor.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,7 @@ protected virtual void Dispose(bool disposing)
141141
{
142142
if (disposing)
143143
{
144+
this.internalExecutor.Dispose();
144145
this.service.Dispose();
145146
}
146147

dotnet/src/webdriver/WebDriver.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -712,6 +712,8 @@ protected virtual void Dispose(bool disposing)
712712
{
713713
this.sessionId = null;
714714
}
715+
716+
this.executor.Dispose();
715717
}
716718

717719
private static void UnpackAndThrowOnError(Response errorResponse)

0 commit comments

Comments
 (0)