Example of testing a RPC call using GWT-TestCase with GAE

Posted by Stephen Cagle on Stack Overflow See other posts from Stack Overflow or by Stephen Cagle
Published on 2009-06-09T20:56:05Z Indexed on 2010/03/14 1:55 UTC
Read the original article Hit count: 597

Filed under:
|
|

How is that for a lot of acronyms!

I am having trouble testing GWT's RPC mechanism using GWT's GWTTestCase. I created a class for testing using the junitCreator tool included with GWT. I am attempting to test using the built in Google App Engine using the created "hosted mode" testing profile created by junitCreator. When I run the test, I keep getting errors saying things like

Starting HTTP on port 0
   HTTP listening on port 49569
The development shell servlet received a request for 'greet' in module 'com.google.gwt.sample.stockwatcher.StockWatcher.JUnit.gwt.xml' 
   [WARN] Resource not found: greet; (could a file be missing from the public path or a <servlet> tag misconfigured in module com.google.gwt.sample.stockwatcher.StockWatcher.JUnit.gwt.xml ?)
com.google.gwt.user.client.rpc.StatusCodeException: Cannot find resource 'greet' in the public path of module 'com.google.gwt.sample.stockwatcher.StockWatcher.JUnit'

I hope that someone somewhere has successfully run junit test (using GWTTestCase or just plain TestCase) that will allow for the testing of gwt RPC. If this is the case, could you please mention the steps you took, or better yet, just post code that works. Thanks.

© Stack Overflow or respective owner

Related posts about google-app-engine

Related posts about gwt