}
private void reportVersion(RemoteWebDriver driver) {
if (reportedVersion) { return; }
reportedVersion = true;
Capabilities caps = driver.getCapabilities();
String name = caps.getBrowserName();
if (name == null) { name = "unknown"; }
String version = caps.getVersion();
if (version == null) { version = "unknown"; }
// Firefox's version is something like "20.0", which doesn't tell
// you the exact build, so we also try to report buildID.
String build = (String) executeScript(
"return String(navigator.buildID || '')");