Am completely new in android and Google App Engine staff. i want to run a junit test on one of my class methods. but i have received an exception which i have tried to google for solns but all in vain.
am using android studio 1.3 on ubuntu Ubuntu 15.04 64bit.
help is appreciated
here's the error that am getting from my android studio console
java.util.ServiceConfigurationError: com.google.appengine.tools.development.LocalRpcService: Provider com.google.appengine.api.datastore.dev.LocalCloudDatastoreV1Service could not be instantiated at java.util.ServiceLoader.fail(ServiceLoader.java:232) at java.util.ServiceLoader.access$100(ServiceLoader.java:185) at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:384) at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404) at java.util.ServiceLoader$1.next(ServiceLoader.java:480) at com.google.appengine.tools.development.ApiProxyLocalImpl.startServices(ApiProxyLocalImpl.java:604) at com.google.appengine.tools.development.ApiProxyLocalImpl.access$700(ApiProxyLocalImpl.java:46) at com.google.appengine.tools.development.ApiProxyLocalImpl$2.run(ApiProxyLocalImpl.java:588) at com.google.appengine.tools.development.ApiProxyLocalImpl$2.run(ApiProxyLocalImpl.java:585) at java.security.AccessController.doPrivileged(Native Method) at com.google.appengine.tools.development.ApiProxyLocalImpl.getService(ApiProxyLocalImpl.java:584) at com.google.appengine.tools.development.ApiProxyLocalImpl$AsyncApiCall.callInternal(ApiProxyLocalImpl.java:500) at com.google.appengine.tools.development.ApiProxyLocalImpl$AsyncApiCall.call(ApiProxyLocalImpl.java:479) at
it's really a big stalktrace!!!!
Am completely new in android and Google App Engine staff. i want to run a junit test on one of my class methods. but i have received an exception which i have tried to google for solns but all in vain.
am using android studio 1.3 on ubuntu Ubuntu 15.04 64bit.
here's the error that am getting from my android studio console
java.util.ServiceConfigurationError: com.google.appengine.tools.development.
LocalRpcService: Provider com.google.appengine.api.datastore.dev
.
LocalCloudDatastoreV1Service could not be instantiated
at java.util.ServiceLoader.fail(ServiceLoader.java:232)
at java.util.ServiceLoader.access$100(ServiceLoader.java:185)
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:384)
at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404)
at java.util.ServiceLoader$1.next(ServiceLoader.java:480)
at com.google.appengine.tools.development.ApiProxyLocalImpl.startServices(ApiProxyLocalImpl.java:600)
at com.google.appengine.tools.development.ApiProxyLocalImpl.access$700(ApiProxyLocalImpl.java:46)
at com.google.appengine.tools.development.ApiProxyLocalImpl$2.run(ApiProxyLocalImpl.java:584)
at com.google.appengine.tools.development.ApiProxyLocalImpl$2.run(ApiProxyLocalImpl.java:581)
at java.security.AccessController.doPrivileged(Native Method)
at com.google.appengine.tools.development.ApiProxyLocalImpl.getService(ApiProxyLocalImpl.java:580)
at com.google.appengine.tools.development.ApiProxyLocalImpl$AsyncApiCall.callInternal(ApiProxyLocalImpl.java:496)
at com.google.appengine.tools.development.ApiProxyLocalImpl$AsyncApiCall.call(ApiProxyLocalImpl.java:475)
at com.google.appengine.tools.development.ApiProxyLocalImpl$AsyncApiCall.call(ApiProxyLocalImpl.java:452)
at java.util.concurrent.Executors$PrivilegedCallable$1.run(Executors.java:533)
at java.security.AccessController.doPrivileged(Native Method)
at java.util.concurrent.Executors$PrivilegedCallable.call(Executors.java:530)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
what should i do to solve the problem?
UPDATE Here is my LocalServiceTestHelper declaration.
public class MyClassTest {
static {
ObjectifyService.register(AccountUser.class);
}
LocalServiceTestHelper helper =
new LocalServiceTestHelper(new LocalDatastoreServiceTestConfig());
@Before
public void setUp() {
helper.setUp();
}
@After
public void tearDown() {
helper.tearDown();
}
@Test
public void myClassMethodUnderTest() throws Exception {
//method codes are here e.g
AccountUser user1 = new AccountUser();
user1.setFirstName("Daniel");
user1.setLastName("Toroitich-Arap-Moi");
user1.setEmail("M...@Gmail.com");
user1.setId(new Long(1));
ofy().save().entity(user1).now();
}
}
I'm completely new in android and Google App Engine staff. I want to run a JUnit
test on one of my class methods. But I have received an exception which I have tried to google for solns
but all in vain.
I am using android studio 1.3 on ubuntu Ubuntu 15.04 64bit.
Here's the error that am getting from my android studio console
java.util.ServiceConfigurationError: com.google.appengine.tools.development. LocalRpcService: Provider com.google.appengine.api.datastore.dev. LocalCloudDatastoreV1Service could not be instantiated
at java.util.ServiceLoader.fail(ServiceLoader.java:232) at java.util.ServiceLoader.access$100(ServiceLoader.java:185) at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:384) at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404) at java.util.ServiceLoader$1.next(ServiceLoader.java:480) at com.google.appengine.tools.development.ApiProxyLocalImpl.startServices(ApiProxyLocalImpl.java:600) at com.google.appengine.tools.development.ApiProxyLocalImpl.access$700(ApiProxyLocalImpl.java:46) at com.google.appengine.tools.development.ApiProxyLocalImpl$2.run(ApiProxyLocalImpl.java:584) at com.google.appengine.tools.development.ApiProxyLocalImpl$2.run(ApiProxyLocalImpl.java:581) at java.security.AccessController.doPrivileged(Native Method) at com.google.appengine.tools.development.ApiProxyLocalImpl.getService(ApiProxyLocalImpl.java:580) at com.google.appengine.tools.development.ApiProxyLocalImpl$AsyncApiCall.callInternal(ApiProxyLocalImpl.java:496) at com.google.appengine.tools.development.ApiProxyLocalImpl$AsyncApiCall.call(ApiProxyLocalImpl.java:475) at com.google.appengine.tools.development.ApiProxyLocalImpl$AsyncApiCall.call(ApiProxyLocalImpl.java:452) at java.util.concurrent.Executors$PrivilegedCallable$1.run(Executors.java:533) at java.security.AccessController.doPrivileged(Native Method) at java.util.concurrent.Executors$PrivilegedCallable.call(Executors.java:530) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)
What should I do to solve the problem?