TestSuite with GWT

GWT Designer allows you to quickly create the modules, composites, panels, remote services and other elements that comprise Google Web Tookit applications.

Moderators: Konstantin.Scheglov, gnebling, Alexander.Mitin, jwren, Eric Clayberg

TestSuite with GWT

Postby muks » Fri Nov 16, 2007 11:15 am

I tried to create a JUnit TestSuite within a GWT.

Added this to the Test Module as suggested in the Recipe.

The compiler produces the following error:

junit.framework.TestSuite can not be found in source packages. Check the inheritance chain from your module; it may not be inheriting a required module or a module may not be adding its source path entries properly. Test/src/com/mycompany/test/client AllTests.java

I added <inherits name="junit.framework.TestSuite"/> to gwt.xml. But still the error persists.

However when I setup the JUnit Run Configuration, it runs alright but with the following msg:
Analyzing source in module 'com.mycompany.test.ImageViewer2Test'
[ERROR] Errors in 'C:\SESWorkspace\Test\src\com\mycompany\test\client\AllTests.java'
[ERROR] Line 4: The import junit.framework.TestSuite cannot be resolved
[ERROR] Line 9: TestSuite cannot be resolved to a type
[ERROR] Line 9: TestSuite cannot be resolved to a type

Junit runs successfully however.

Is there a way to avoid these messages?
muks
 
Posts: 3
Joined: Wed Nov 14, 2007 4:07 pm

Postby Konstantin.Scheglov » Tue Nov 20, 2007 3:27 am

Note, that "recipe" is mostly deprecated because GWT Designer now supports launching JUnit tests, so you don't need any "launch level" classpath tweaks.

TestSuite is not part of GWT (in contrast to GWTTestCase), so you should more TestSuite outside of GWT module (GWT Designer still will able to run it).
Konstantin.Scheglov
Moderator
 
Posts: 186
Joined: Tue Oct 18, 2005 8:11 pm
Location: Russian Federation, Lipetsk

Postby Eric Clayberg » Tue Nov 20, 2007 10:26 am

Here are the docs for the new JUnit GWT Application launch configuration.

Image
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA


Return to GWT Designer

Who is online

Users browsing this forum: No registered users and 3 guests