Closed magreenblatt closed 3 years ago
Comment 1. originally posted by magreenblatt on 2012-03-15T14:32:02.000Z:
Comment 2. originally posted by magreenblatt on 2012-08-09T15:36:38.000Z:
The CEF3 implementation will be based on the Chromium automation API currently under development. More information: https://groups.google.com/a/chromium.org/forum/?fromgroups&hl=en\#!topic/chromium-dev/vQMRxI6HFl4%5B1-25%5D
Original comment by Anonymous.
Comment 3. originally posted by jmayhew@google.com on 2012-10-19T23:31:40.000Z:
Just curious if you know of any update on this work. The last post in the thread you linked to was from July. I am very interested in using webdriver to create automated tests for CEF hosted pages.
If it is stalled and there is any way I can help let me know.
Comment 4. originally posted by magreenblatt on 2012-10-22T19:25:19.000Z:
Test automation for CEF3 can be implemented currently using the DevTools remote debugging protocol. For example: http://www.igvita.com/2012/04/09/driving-google-chrome-via-websocket-api/
Google has decided to implement WebDriver support as an extension of the DevTools protocol. More information in this thread: https://groups.google.com/a/chromium.org/forum/?fromgroups=\#!topic/chromium-dev/yGta7vfanp8
General information on remote debugging: https://developers.google.com/chrome-developer-tools/docs/remote-debugging
Original comment by Anonymous.
Comment 5. originally posted by binod80 on 2012-12-10T16:26:17.000Z:
Any thoughts on the expected release of this functionality? I am looking into support my development team who are using CEF to build their products, and they want us to develop support for automated testing. I am wondering how much effort we should expend our efforts, and if we were to expect CEF-webdriver support, what the anticipated dates would be.
Comment 6. originally posted by magreenblatt on 2012-12-10T16:34:01.000Z:
@ comment comment 5.: The remote debugging protocol can currently be used for automated testing. You don't need to wait for the extensions that Google is proposing.
Original comment by Anonymous.
Comment 7. originally posted by binod80 on 2012-12-10T19:59:10.000Z:
@ comment 6: Thanks for the update. If I want to provide users with a Java api that has the look and feel of the webdriver style api to control and drive CEF windows, without having access to the extensions (so I can eventually start using the webdriver support once available without users knowing about the switch), is the recommended approach then to wrap around the debugging protocol with my Java api?
Also, when the webdriver support is available, will it be a different driver executable (similar to chromedriver.exe) that works with the existing ChromeDriver client apis?
Thanks
Original comment by Anonymous.
Comment 8. originally posted by alavers@system42.net on 2012-12-10T21:18:31.000Z:
There's a chrome dev tools Java API:
Original comment by Anonymous.
Comment 9. originally posted by binod80 on 2013-01-04T19:29:40.000Z:
Thanks for the pointer here. I have tried to use the Java SDK for chromedevtools and I am basically able to get some info such as tab count, url , title etc. But it was not so clear whether I could navigate, find elements etc.
The question is: if I want to use a ChromeDriver Java api for controlling a CEF window, should I go ahead and try to build a webdriver implementation using the sdk as the basis, or is there a shorter route, such as modifying the existing Chromedriver, and making it connect to CEF instead of Chrome? CEF in my case is already up and running unlike the chrome case with ChromeDriver Java.
Original comment by Anonymous.
Comment 10. originally posted by umair.chagani on 2013-02-04T18:23:44.000Z:
Was there any update to this? Will WebDriver be supported?
Comment 11. originally posted by magreenblatt on 2013-04-30T15:07:36.000Z:
Google has released an alpha of ChromeDriver2, the re-implementation of ChromeDriver using the DevTools remote debugging protocol. I haven't looked at it in detail to determine what changes, if any, are required to use it with CEF3. https://code.google.com/p/chromedriver/wiki/ChromeDriver2
Original comment by Anonymous.
Comment 12. originally posted by Daniel.Shaulov on 2013-06-24T06:52:13.000Z:
It seems that the ChromeDriver2 Project has graduated to release, the wiki says it is the recommended one and Downloads lists the 1.* as deprecated.
Original comment by Anonymous.
Comment 13. originally posted by Daniel.Shaulov on 2013-06-24T18:08:42.000Z:
I have tested the latest ChromeDriver2 and it works with CEF.
Search location for your app can be set like so:
ChromeOptions options = new ChromeOptions();
options.setBinary("/path/to/your/app.exe");
WebDriver driver = new ChromeDriver(options);
make sure you are getting your remote debugging port from command line and not setting it manually.
Original comment by Anonymous.
Comment 14. originally posted by breynolds@promia.com on 2013-06-26T05:44:56.000Z:
Is that with CEF1 or CEF3?
From Java, using
ChromeOptions options = new ChromeOptions();
options.setBinary("blah\\cef_binary_3.1364.1094_windows\\Release\\cefclient.exe");
WebDriver driver = new ChromeDriver(options);
shows
[0.892][INFO]: received WebDriver request: GET /status
[0.893][INFO]: sending WebDriver response: 200 {
"sessionId": "",
"status": 0,
"value": {
"build": {
"version": "alpha"
},
"os": {
"arch": "x86_64",
"name": "Windows NT",
"version": "6.1 SP1"
}
}
}
[1.072][INFO]: received WebDriver request: POST /session {
"desiredCapabilities": {
"browserName": "chrome",
"chrome.binary": "blah\\cef_binary_3.1364.1094_windows\\Release\\cefclient.exe",
"chrome.switches": [ ],
"chromeOptions": {
"args": [ ],
"binary": "blah\\cef_binary_3.1364.1094_windows\\Release\\cefclient.exe",
"extensions": [ ]
},
"platform": "ANY",
"version": ""
}
}
[1.085][INFO]: Launching chrome: "blah\cef_binary_3.1364.1094_windows\Release\cefclient.exe" --remote-debugging-port=51017 --no-first-run --enable-logging --logging-level=1 --user-data-dir="C:\Users\bill-lap\AppData\Local\Temp\scoped_dir11456_21147" --load-extension="C:\Users\bill-lap\AppData\Local\Temp\scoped_dir11456_24744\internal" --ignore-certificate-errors data:text/html;charset=utf-8,
[3.891][INFO]: sending WebDriver response: 200 {
"sessionId": "",
"status": 13,
"value": {
"message": "unknown error: Chrome version must be \u003E= 27.0.1453.0\nfrom unknown error: version info doesn't include string 'Browser'\n (Driver info: chromedriver=2.0,platform=Windows NT 6.1 SP1 x86_64)"
}
}
org.openqa.selenium.WebDriverException: unknown error: Chrome version must be >= 27.0.1453.0
from unknown error: version info doesn't include string 'Browser'
(Driver info: chromedriver=2.0,platform=Windows NT 6.1 SP1 x86_64) (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 4.07 seconds
Build info: version: '2.33.0', revision: '4e90c97', time: '2013-05-22 15:33:32'
System info: os.name: 'Windows 7', os.arch: 'x86', os.version: '6.1', java.version: '1.7.0_03'
Driver info: org.openqa.selenium.chrome.ChromeDriver
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:191)
at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:145)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:554)
at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:216)
at org.openqa.selenium.remote.RemoteWebDriver.
at org.openqa.selenium.remote.RemoteWebDriver.
at org.openqa.selenium.chrome.ChromeDriver.
at org.openqa.selenium.chrome.ChromeDriver.
at Test.testGoogleSearch(Test.java:23)
at Test.main(Test.java:40)
Original comment by Anonymous.
Comment 15. originally posted by Daniel.Shaulov on 2013-06-26T06:02:12.000Z:
This is only about CEF3.
You need to update CEF - you need at least 3.1453.* (latest binary release seems ok). You have 3.1364.*
I was compiling latest from source, so even if latest binary is not working, it will work in the next binary release.
Original comment by Anonymous.
Comment 16. originally posted by amol.moye on 2013-08-08T18:54:50.000Z:
Unfortunately, looks like the wiki page for Chromdriver 2 has been taken down. Has this effort been abandoned?
Comment 17. originally posted by magreenblatt on 2013-08-08T19:04:12.000Z:
@ commentcomment 16.: ChromeDriver2 is now the current version (no longer alpha/beta). Not sure what happened to the wiki page.
Comment 18. originally posted by magreenblatt on 2013-08-15T19:40:38.000Z:
ChromeDriver2 has been verified to work with CEF3.
Original comment by Anonymous.
Comment 19. originally posted by deepakyadav9919 on 2013-08-20T13:11:26.000Z:
I have tried to open my binary using below code :
File chromium = new File("D:\\CefClient\\CefClient\\cefclient.exe");
System.setProperty("webdriver.chrome.driver","C:/Users/deepaky/workspace/support_bijli/src/chromedriver.exe");
ChromeOptions options = new ChromeOptions();
options.setBinary(chromium);
WebDriver driver = new ChromeDriver(options);
it launched the application but after that it thrown the error below and am not getting why i got this
Exception in thread "main" org.openqa.selenium.WebDriverException: chrome not reachable
(Driver info: chromedriver=2.2,platform=Windows NT 6.1 SP1 x86_64) (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 24.59 seconds
Build info: version: '2.25.0', revision: '17482', time: '2012-07-18 21:09:54'
System info: os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '1.7.0_25'
Driver info: driver.version: ChromeDriver
Session ID: 670acb9e9f33f35dd7586ec7cff68576 (bb)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:188)
at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:145)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:498)
at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:182)
at org.openqa.selenium.remote.RemoteWebDriver.
at org.openqa.selenium.remote.RemoteWebDriver.
at org.openqa.selenium.chrome.ChromeDriver.
at org.openqa.selenium.chrome.ChromeDriver.
at Chromiumtest.test2.main(test2.java:20)
Original comment by Anonymous.
Comment 20. originally posted by Daniel.Shaulov on 2013-08-20T13:14:59.000Z:
Is it possible you are setting "remote_debugging_port" manually instead of letting it come from the command line?
Original comment by Anonymous.
Comment 21. originally posted by deepakyadav9919 on 2013-08-21T05:23:53.000Z:
no,because everytime it launches on different port
Comment 22. originally posted by magreenblatt on 2014-02-24T15:10:42.000Z:
issue #1218 has been merged into this issue.
Original comment by Anonymous.
Comment 23. originally posted by zhangwei8607 on 2014-06-12T02:56:01.000Z:
[21.310][INFO]: sending WebDriver response: 200 {
"sessionId": "",
"status": 100,
"value": {
"message": "chrome not reachable\\n (Driver info: chromedriver=0.9,platform=Windows NT 6.1 SP1 x86\_64)"
}
}
[21.337][INFO]: received WebDriver request: GET /shutdown
[21.337][INFO]: sending WebDriver response: 200 {
"sessionId": "",
"status": 0,
"value": null
}
Started ChromeDriver (v0.9) on port 10984
Exception in thread "main" org.openqa.selenium.WebDriverException: chrome not reachable
(Driver info: chromedriver=0.9,platform=Windows NT 6.1 SP1 x86_64) (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 21.40 seconds
Build info: version: '2.40.0', revision: 'fbe29a9', time: '2014-02-19 20:55:11'
System info: host: 'PVGD50803902A', ip: '10.58.93.111', os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '1.7.0_09'
Driver info: org.openqa.selenium.chrome.ChromeDriver
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:193)
at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:145)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:573)
at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:218)
at org.openqa.selenium.chrome.ChromeDriver.startSession(ChromeDriver.java:181)
at org.openqa.selenium.remote.RemoteWebDriver.
at org.openqa.selenium.remote.RemoteWebDriver.
at org.openqa.selenium.chrome.ChromeDriver.
at org.openqa.selenium.chrome.ChromeDriver.
at org.openqa.selenium.chrome.ChromeDriver.
at test.selenium.testSetup.main(testSetup.java:35)
Original comment by Anonymous.
Comment 24. originally posted by zhangwei8607 on 2014-06-12T02:57:21.000Z:
Anyone could help with above error, using chromdriver2 and CEF3
Original comment by Anonymous.
Comment 25. originally posted by lee.gixxer on 2014-06-19T15:42:49.000Z:
Zhangwei are you using the latest chromedriver? http://chromedriver.storage.googleapis.com/index.html?path=2.10/ I also got this working with the latest version of CEF3
Original comment by Anonymous.
Comment 26. originally posted by zabrane3 on 2014-06-19T16:33:37.000Z:
Hi Lee,
Can you post the steps you've followed to get it work please?
Thx
Zab
Original comment by Anonymous.
Comment 27. originally posted by ldavis@compcc.com on 2014-06-20T20:23:02.000Z:
Zab
I don't have a tonne of details, but what I can give you is what we used to prove this out, we used Ubuntu 13.10 and CEF3 prebuilt binaries. (http://cefbuilds.com/) I believe 1750 at the time.
Used selenium webdriver 2.41.0 and chromedriver 2.9.
Set the remote debug address using flags see: http://peter.sh/experiments/chromium-command-line-switches/
Connected to the remote address using the experimental options in chromedriver: options.setExperimentalOption("debuggerAddress", "127.0.0.1:8088")
See: https://sites.google.com/a/chromium.org/chromedriver/capabilities (The docs are not 100% perfectly accurate. Check the changelog and source)
We then manually fired up the CEF build with the necessary flags and remotely connected to it and started running tests.
I believe there was a couple hoops we had to jump through for read\write permissions or default flag settings in our custom CEF3 build...
The test platform was grails with geb/spock...
I hope that helps.
Cheers
Lee
Original comment by Anonymous.
Comment 28. originally posted by zhangwei8607 on 2014-07-15T04:04:18.000Z:
Hi Lee,
I had a CEF3 application, but I can't launch it successfully. The application will redirect the localhost:port to a servlet url. Could you help how could I launch it.
The log is below:
[9.093][INFO]: received WebDriver request: GET /h5v2/index.html
[9.093][INFO]: sending WebDriver response: 404 unknown command: h5v2/index.html
[26.775][INFO]: sending WebDriver response: 200 {
"sessionId": "",
"status": 100,
"value": {
"message": "chrome not reachable\\n (Driver info: chromedriver=0.9,platform=Windows NT 6.1 SP1 x86\_64)"
}
}
Original comment by Anonymous.
Comment 29. originally posted by ananthnalluri on 2014-08-12T11:24:49.000Z:
Hi All,
I have a CEF3 application built on below details, can someone help me how to launch it with Selenium/chromedriver
application details:
CEF: 3.1916.1701
Chromium: 35.0.1916.86
OS: Windows
WebKit: 537.36
JavaScript: 3.25.28.15
Flash:
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1916.86 Safari/537.36
Command Line: cefclient.exe --no-sandbox --lang=en-US help
Module Path: C:\Program Files (x86)\
Cache Path: C:\Users\
What I used:
selenium webdriver java 2.41.0 and chromedriver 2.10
code:
System.setProperty("webdriver.chrome.driver", "C:\\webdrivers\\chromedriver.exe");
ChromeOptions options = new ChromeOptions();
options.setBinary(new File("C:\Program Files (x86)\
options.addArguments("--no-sandbox --lang=en-us");
WebDriver cefDriver=new ChromeDriver(options);
Console:
Starting ChromeDriver (v2.10.267521) on port 33000
Only local connections are allowed.
Exception in thread "main" org.openqa.selenium.WebDriverException: unknown error: Chrome failed to start: crashed
(Driver info: chromedriver=2.10.267521,platform=Windows NT 6.1 SP1 x86_64) (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 61.71 seconds
Build info: version: '2.41.0', revision: '3192d8a', time: '2014-03-27 17:18:15'
Original comment by Anonymous.
Comment 30. originally posted by cinnysavitri on 2014-12-18T08:55:26.000Z:
Hi,
I will be using Google Chrome within an application i.e Chrome Embedded within an application.
Can webdriver be used to test that browser which is opening within the application.
Thanks,
Cinny
Comment 31. originally posted by magreenblatt on 2015-02-11T23:50:34.000Z:
I've added a short tutorial explaining how to automate CEF with ChromeDriver and Java: https://code.google.com/p/chromiumembedded/wiki/UsingChromeDriver
Original comment by Ramya Gr (Bitbucket: Ramyagr, GitHub: Ramyagr).
Hi @magreenblatt
I referred to the tutorial you have mentioned above, which is currently available under https://bitbucket.org/chromiumembedded/cef/wiki/UsingChromeDriver. I am working on Mac OS, using latest ChromeDriver 2.22. Our application is on CEF. I am trying to automate it in Selenium using Java. But I have the same problem as mentioned by others above, "Chrome not reachable" is displayed.
System.setProperty("webdriver.chrome.driver", "chromedriver"); ChromeOptions options = new ChromeOptions();
options.setBinary("/Users/Auto/ABC.app/Contents/MacOS/ABC");
//options.setExperimentalOption("debuggerAddress", "192.0.10.0:12345");
WebDriver driver = new ChromeDriver(options); sleep(1000);
When I provide setExperimentalOption, my app does not even start. On commenting it and running, it opens my application. But then closes after some time.
Console: Starting ChromeDriver 2.22.397929 (fb72fb249a903a0b1041ea71eb4c8b3fa0d9be5a) on port 13154 Only local connections are allowed.
After some time the application closes and I see the below info in debugger. chrome not reachable (Driver info: chromedriver=2.22.397929 (fb72fb249a903a0b1041ea71eb4c8b3fa0d9be5a),platform=Mac OS X 10.11.5 x86_64) (WARNING: The server did not provide any stacktrace information) Command duration or timeout: 60.56 seconds
Any help would be highly appreciated.
Original comment by CnuMagapu (Bitbucket: CnuMagapu, GitHub: CnuMagapu).
Hi @Marshall Greenblatt
I tried the same that you mentioned under https://bitbucket.org/chromiumembedded/cef/wiki/UsingChromeDriver
But i'm getting an error i.e. org.openqa.selenium.SessionNotCreatedException
i'm using Chrome driver: 2.42, chrome browser 69v
Here is the stacktrace: Exception in thread "main" org.openqa.selenium.SessionNotCreatedException: session not created: Chrome version must be >= 68.0.3440.0 (Driver info: chromedriver=2.42.591088 (7b2b2dca23cca0862f674758c9a3933e685c27d5),platform=Windows NT 10.0.14393 x86_64) (WARNING: The server did not provide any stacktrace information) Command duration or timeout: 60.36 seconds Build info: version: '3.4.0', revision: 'unknown', time: 'unknown' System info: host: 'XXX
', ip: '1xx.xxx.x.xxx', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_112'
Driver info: driver.version: ChromeDriver
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:215)
at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:167)
at org.openqa.selenium.remote.JsonWireProtocolResponse.lambda$new$0(JsonWireProtocolResponse.java:53)
at org.openqa.selenium.remote.JsonWireProtocolResponse.lambda$getResponseFunction$2(JsonWireProtocolResponse.java:91)
at org.openqa.selenium.remote.ProtocolHandshake.lambda$createSession$22(ProtocolHandshake.java:365)
at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
at java.util.Spliterators$ArraySpliterator.tryAdvance(Spliterators.java:958)
at java.util.stream.ReferencePipeline.forEachWithCancel(ReferencePipeline.java:126)
at java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:498)
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:485)
at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
at java.util.stream.FindOps$FindOp.evaluateSequential(FindOps.java:152)
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.util.stream.ReferencePipeline.findFirst(ReferencePipeline.java:464)
at org.openqa.selenium.remote.ProtocolHandshake.createSession(ProtocolHandshake.java:368)
at org.openqa.selenium.remote.ProtocolHandshake.createSession(ProtocolHandshake.java:159)
at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:142)
at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(DriverCommandExecutor.java:82)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:637)
at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:250)
at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:236)
at org.openqa.selenium.remote.RemoteWebDriver.
#!java
System.setProperty("webdriver.chrome.driver", "C://Users//chromedriver.exe");
ChromeOptions options = new ChromeOptions();
// Path to the CEF executable.
options.setBinary("C:/Program Files (x86)/cefApplication.exe");
// Port to communicate on. Required starting with ChromeDriver v2.42.
options.addArguments("remote-debugging-port=55555");
WebDriver driver = new ChromeDriver(options);
//driver.get("http://www.google.com/xhtml");
Thread.sleep(3000); // Let the user actually see something!
WebElement searchBox = driver.findElement(By.name("username"));
searchBox.sendKeys("ChromeDriver");
searchBox.submit();
Thread.sleep(3000); // Let the user actually see something!
driver.quit();
Please help me
Thanks in advance Srinivas
Original report by me.
Original issue 549 created by magreenblatt on 2012-03-15T14:31:57.000Z:
WebDriver is an implementation of the selenium browser automation framework (http://code.google.com/p/selenium/). The implementation currently lives inside the browser/ folder but it should ideally be able to drive any WebKit-based browser.
The WebDriver implementation in Chrome is currently composed of two parts:
A separate WebDriver executable (chrome/test/webdriver) that drives the Chrome executable.
The WebDriver automation layer (chrome/test/automation, chrome/browser/automation) built into the Chrome executable.
The WebDriver executable can potentially be shared between the Chrome browser and other consumers of the content API. The WebDriver automation layer can be refactored into a series of delegates that allow Chrome and other consumers of the content API to provide their own implementations.
Original chromium-dev thread on this topic:
http://groups.google.com/a/chromium.org/group/chromium-dev/browse\_thread/thread/1df42d7895c4f677#
Chromium issue: http://code.google.com/p/chromium/issues/detail?id=110619