Skip to content

Commit 3818819

Browse files
authored
Throw a descriptive exception if the current dev tools version is not… (SeleniumHQ#11876)
Throw a descriptive exception if the current dev tools version is not supported
1 parent 9b2b385 commit 3818819

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

dotnet/src/webdriver/DevTools/DevToolsDomains.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,7 @@ private static Type MatchDomainsVersion(int desiredVersion, int versionRange)
127127
}
128128
}
129129

130-
// TODO: Return a no-op implementation or throw exception.
131-
return null;
130+
throw new WebDriverException($"DevTools version is not in the supported range. Desired version={desiredVersion}, range={versionRange}. Supported versions: {string.Join(", ", supportedVersions)}");
132131
}
133132
}
134133
}

0 commit comments

Comments
 (0)