Skip to content

Commit eb1cd1e

Browse files
authored
Merge branch 'trunk' into jspecify-enums
2 parents bcf3a6a + a62ef3d commit eb1cd1e

File tree

422 files changed

+642
-28169
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

422 files changed

+642
-28169
lines changed

.github/workflows/update-documentation.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -140,10 +140,6 @@ jobs:
140140
run: |
141141
git config --local user.email "[email protected]"
142142
git config --local user.name "Selenium CI Bot"
143-
- name: Install specific version of DocFX tool
144-
# Pinning to 2.75.3 to avoid breaking changes in newer versions
145-
# See https://github.com/dotnet/docfx/issues/9855
146-
run: dotnet tool install --global --version 2.75.3 docfx
147143
- name: Update Documentation
148144
if: needs.determine-language.outputs.language == 'all' || needs.determine-language.outputs.language == 'dotnet'
149145
run: ./go dotnet:docs

MODULE.bazel

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ register_toolchains("@dotnet_toolchains//:all")
9393
oci = use_extension("@rules_oci//oci:extensions.bzl", "oci")
9494
oci.pull(
9595
name = "java_image_base",
96-
digest = "sha256:161a1d97d592b3f1919801578c3a47c8e932071168a96267698f4b669c24c76d",
96+
digest = "sha256:1df9f3e6a2de0544dd04f1840aa811d334045c9126f9e93d8da45448061ad51e",
9797
image = "gcr.io/distroless/java17",
9898
)
9999
oci.pull(

Rakefile

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -777,10 +777,9 @@ namespace :dotnet do
777777
task :docs, [:skip_update] do |_task, arguments|
778778
FileUtils.rm_rf('build/docs/api/dotnet/')
779779
begin
780-
# Pinning to 2.75.3 to avoid breaking changes in newer versions
781-
# See https://github.com/dotnet/docfx/issues/9855
780+
# Pinning to 2.78.2 to avoid breaking changes in newer versions
782781
sh 'dotnet tool uninstall --global docfx || true'
783-
sh 'dotnet tool install --global --version 2.75.3 docfx'
782+
sh 'dotnet tool install --global --version 2.78.2 docfx'
784783
# sh 'dotnet tool update -g docfx'
785784
rescue StandardError
786785
puts 'Please ensure that .NET SDK is installed.'

dotnet/NuGet.Config

Lines changed: 0 additions & 6 deletions
This file was deleted.

dotnet/docs/docfx.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
],
1212
"dest": "webdriver",
1313
"namespaceLayout": "nested",
14-
"outputFormat": "apiPage"
14+
//"outputFormat": "apiPage" // "apiPage" generation with errors
1515
},
1616
{
1717
"src": [
@@ -24,9 +24,8 @@
2424
],
2525
"dest": "support",
2626
"namespaceLayout": "nested",
27-
"outputFormat": "apiPage"
27+
//"outputFormat": "apiPage" // "apiPage" generation with errors
2828
}
29-
3029
],
3130
"build": {
3231
"content": [

dotnet/private/merge_assemblies.bzl

Lines changed: 0 additions & 97 deletions
This file was deleted.

dotnet/private/nuget.bzl

Lines changed: 0 additions & 150 deletions
This file was deleted.

dotnet/src/webdriver/Interactions/ActionBuilder.cs

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@
2121
using System.Collections.Generic;
2222
using System.Text;
2323

24+
#nullable enable
25+
2426
namespace OpenQA.Selenium.Interactions
2527
{
2628
/// <summary>
@@ -29,7 +31,7 @@ namespace OpenQA.Selenium.Interactions
2931
/// </summary>
3032
public class ActionBuilder
3133
{
32-
private Dictionary<InputDevice, ActionSequence> sequences = new Dictionary<InputDevice, ActionSequence>();
34+
private readonly Dictionary<InputDevice, ActionSequence> sequences = new Dictionary<InputDevice, ActionSequence>();
3335

3436
/// <summary>
3537
/// Adds an action to the built set of actions. Adding an action will
@@ -71,7 +73,7 @@ public IList<ActionSequence> ToActionSequenceList()
7173
/// </summary>
7274
public void ClearSequences()
7375
{
74-
this.sequences = new Dictionary<InputDevice, ActionSequence>();
76+
this.sequences.Clear();
7577
}
7678

7779
/// <summary>
@@ -94,8 +96,7 @@ private void ProcessTick(params Interaction[] interactionsToAdd)
9496
List<InputDevice> usedDevices = new List<InputDevice>();
9597
foreach (Interaction interaction in interactionsToAdd)
9698
{
97-
InputDevice actionDevice = interaction.SourceDevice;
98-
if (usedDevices.Contains(actionDevice))
99+
if (usedDevices.Contains(interaction.SourceDevice))
99100
{
100101
throw new ArgumentException("You can only add one action per device for a single tick.");
101102
}
@@ -104,8 +105,9 @@ private void ProcessTick(params Interaction[] interactionsToAdd)
104105
List<InputDevice> unusedDevices = new List<InputDevice>(this.sequences.Keys);
105106
foreach (Interaction interaction in interactionsToAdd)
106107
{
107-
ActionSequence sequence = this.FindSequence(interaction.SourceDevice);
108+
ActionSequence sequence = this.GetOrAddSequence(interaction.SourceDevice);
108109
sequence.AddAction(interaction);
110+
109111
unusedDevices.Remove(interaction.SourceDevice);
110112
}
111113

@@ -116,11 +118,11 @@ private void ProcessTick(params Interaction[] interactionsToAdd)
116118
}
117119
}
118120

119-
private ActionSequence FindSequence(InputDevice device)
121+
private ActionSequence GetOrAddSequence(InputDevice device)
120122
{
121-
if (this.sequences.ContainsKey(device))
123+
if (this.sequences.TryGetValue(device, out ActionSequence? existingSequence))
122124
{
123-
return this.sequences[device];
125+
return existingSequence;
124126
}
125127

126128
int longestSequenceLength = 0;

0 commit comments

Comments
 (0)