Im trying to run embedded elastic servers for Junit test cases. So I just extended a class ESIntegTestCase. But its not allowing me to run the test case. I use elastic search 6.0.0.
My class:
import org.elasticsearch.test.ESIntegTestCase;
import org.junit.Test;
public class AbstractElasticsearchTest extends ESIntegTestCase {
@Test
public void test() {
org.elasticsearch.test.ESTestCase d;
System.out.println("hello");
}
}
Error:
[2018-08-28T19:41:21,230][WARN ][o.e.b.JNANatives ] Unable to lock JVM Memory: error=78,reason=Function not implemented
[2018-08-28T19:41:21,234][WARN ][o.e.b.JNANatives ] This can result in part of the JVM being swapped out. Exception in thread "Thread-1" java.lang.NoClassDefFoundError: Could not initialize class org.elasticsearch.test.ESTestCase
Please help me to resolve it