java.lang.NoClassDefFoundError: com/google/common/base/Charsets

// Selenium Client: selenium-java-2.34.0

// Selenium Server: selenium-server-standalone-2.34.0.jar

// 系统版本:Windows 7 64-bit

 

已正常启动 Selenium Server 的前提下,在 Eclipse 上执行 Selenium 测试脚本出现如下错误:

java.lang.NoClassDefFoundError: com/google/common/base/Charsets

 

解决方法为:在项目的 Build Path 中添加 Selenium Server 的 JAR 包 (如 selenium-server-standalone-2.34.0.jar)。

 

参考资料:http://www.cnblogs.com/limei/archive/2011/10/11.html

你可能感兴趣的:(selenium)