Hi,

I'm developing my own custom Mojo.  I want to test the case where someone
hasn't entered the correct configuration, so my code has …


public class SeleniumTestMojo extends AbstractMojo {

   ...
   public void execute() throws MojoExecutionException {
      try {
         …
            // Verify hosts are non-empty.
         if (hosts != null && hosts.isEmpty()) { 
            throw new MojoExecutionException("Plugin execution requires one
or more hosts.");
         }


I have an XML file that represents the misconfigured plugin, but I have no
idea how to write an integration test to check for this kind of exception. 
Any advice or examples about writing integration tests is greatly
appreciated, - Dave


-- 
View this message in context: 
http://old.nabble.com/Integration-testing-for-my-custom-Mojo-tp32234324p32234324.html
Sent from the mojo - user mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to