无法定位依赖 selenium-webdriver

Unable to locate Dependency selenium-webdriver

我在 Visual Studio 代码 (OS X) 中创建了 ASP .Net 控制台项目。

然后在project.json添加依赖:

"dependencies": {
    "selenium-webdriver": "2.52.0"
},

运行 "dnu restore" 并出现错误:

Microsoft .NET Development Utility CoreClr-x64-1.0.0-rc1-16231

CACHE api.nuget.org/v3/index.json Restoring packages for /Users/user/Code/ConsoleApplication/project.json

GET api.nuget.org/v3-flatcontainer/selenium-webdriver/index.json

NotFound api.nuget.org/v3-flatcontainer/selenium-webdriver/index.json 2432ms

Unable to locate Dependency selenium-webdriver >= 2.52.0 Writing lock file /Users/user/Code/ConsoleApplication/project.lock.json Restore complete, 3027ms elapsed

Errors in /Users/user/Code/ConsoleApplication/project.json Unable to locate Dependency selenium-webdriver >= 2.52.0

Feeds used: https://api.nuget.org/v3-flatcontainer/

所以,答案很简单 - 错字。 id 是 selenium.webdriver,不是 selenium-webdriver