Skip to content

It seems FindDriverServiceExecutable has not been updated to use SeleniumManager in version 4.9? #11942

@jefsmo

Description

@jefsmo
          It seems FindDriverServiceExecutable has not been updated to use SeleniumManager in version 4.9?

Actual:

protected static string FindDriverServiceExecutable(string executableName, Uri downloadUrl)
{
    return FileUtilities.FindFile(executableName);
}

Expected:

protected static string FindDriverServiceExecutable(string executableName, Uri downloadUrl)
{
    string text = FileUtilities.FindFile(executableName);
    if (string.IsNullOrEmpty(text))
    {
        try
        {
            text = Path.GetDirectoryName(SeleniumManager.DriverPath(executableName));
        }
        catch (Exception)
        {
        }

        if (string.IsNullOrEmpty(text))
        {
            throw new DriverServiceNotFoundException(string.Format(CultureInfo.InvariantCulture, "The {0} file does not exist in the current directory or in a directory on the PATH environment variable. The driver can be downloaded at {1}.", executableName, downloadUrl));
        }
    }

    return text;
}

Originally posted by @jefsmo in #11929 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-dotnet.NET BindingsI-defectSomething is not working as intended

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions