Hi ,
Our requirement is run Webdriver script for performance testing.
So we have done integration with Webdriver + JUnit Request and JMeter.
Where we created Webdriver script with JUnit 4 and placed its jar and dependent jar in required folder.
But the problem we are facing is when we try to run the test cases with single or multiple instance, it fails with error for first instance
Error -- firefoxLocal(org.apache.jmeter.protocol.java.sampler.JUnitSampler$AnnotatedTestCase): INSTANCE
and for remaining instances
Error -- firefoxLocal(org.apache.jmeter.protocol.java.sampler.JUnitSampler$AnnotatedTestCase): Could not initialize class org.apache.http.impl.conn.ManagedHttpClientConnectionFactory
Its not able create instance of Webdriver, RemoteWebDriver when we tries to run from JMeter.
Any Help is appreciated
=========================================================================================
public class LoadTest {
@Before
public void setUp() {
System.out.println("========SETUP=========");
}
@After
public void tearDown() {
System.out.println("=======TEARDOWN=======");
}
@Test
public void remoteWedriverTest() throws Exception {
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities = DesiredCapabilities.firefox();
capabilities.setJavascriptEnabled(true);
capabilities.setBrowserName("chrome");
capabilities.setPlatform(org.openqa.selenium.Platform.ANY);
System.out.println("Before Instance");
WebDriver driver = new RemoteWebDriver(new URL(
driver.quit();
}
}
============================================================================================
JMeter Screenshot :

Thanks
Sanit Thale.