[Solved] How to solve java.lang.NoClassDefFoundError? Selenium

The error says it all : java.lang.NoClassDefFoundError: com/google/common/base/Function at MainTest.openGoogle(MainTest.java:15) While working with Selenium v3.x you have to download geckodriver.exe from mozilla/geckodriver and place it in your system. Next you have to set the system property through the line System.setProperty() as follows and provide the absolute path of the GeckoDriver binary within your system as … Read more