Hamcrest GWT

Hamcrest GWT

Abstract: The largest parts of the Hamcrest library can be compiled in GWT. Just the IsInstanceOf class needs a bit of tweaking (as well as some other classes depending on reflection). The following provides a brief overview of some of the steps required to compile Hamcrest with GWT.

  1. 1. Download the Hamcrest GWT SVN Branch (Hamcrest GWT subversion branch) and import to eclipse
bildschirmfoto2010-10-08um18-59-38.png
  1. 2. Clean up the build path (remove the generated folders and remove all other source folders but core, library and gwt)
  2. 3. Copy the classes from the gwt folder into the respective packages in the core folder

4. Import a generated CoreMatchers.java from some distribution (eg from hamcrest-all.jar)

Resources

Issue 50: Hamcrest GWT support Hamcrest GWT subversion branch Google Group Discussion on Hamcrest GWT version