ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dona...@apache.org
Subject cvs commit: jakarta-ant/proposal/myrmidon/src/main/org/apache/tools/ant/taskdefs/optional/junit JUnitTest.java JUnitTask.java
Date Thu, 14 Feb 2002 09:34:27 GMT
donaldp     02/02/14 01:34:27

  Modified:    proposal/myrmidon/src/main/org/apache/tools/ant/taskdefs/optional/junit
                        JUnitTest.java JUnitTask.java
  Log:
  Use the context rather than the project
  
  Revision  Changes    Path
  1.7       +4 -3      jakarta-ant/proposal/myrmidon/src/main/org/apache/tools/ant/taskdefs/optional/junit/JUnitTest.java
  
  Index: JUnitTest.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/src/main/org/apache/tools/ant/taskdefs/optional/junit/JUnitTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- JUnitTest.java	6 Jan 2002 02:28:02 -0000	1.6
  +++ JUnitTest.java	14 Feb 2002 09:34:27 -0000	1.7
  @@ -12,6 +12,7 @@
   import java.util.Iterator;
   import java.util.Properties;
   import org.apache.tools.ant.Project;
  +import org.apache.myrmidon.api.TaskContext;
   
   /**
    * <p>
  @@ -161,14 +162,14 @@
           return m_runs;
       }
   
  -    public boolean shouldRun( Project p )
  +    public boolean shouldRun( final TaskContext context )
       {
  -        if( ifProperty != null && p.getProperty( ifProperty ) == null )
  +        if( ifProperty != null && context.getProperty( ifProperty ) == null )
           {
               return false;
           }
           else if( unlessProperty != null &&
  -            p.getProperty( unlessProperty ) != null )
  +            context.getProperty( unlessProperty ) != null )
           {
               return false;
           }
  
  
  
  1.38      +3 -1      jakarta-ant/proposal/myrmidon/src/main/org/apache/tools/ant/taskdefs/optional/junit/JUnitTask.java
  
  Index: JUnitTask.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/src/main/org/apache/tools/ant/taskdefs/optional/junit/JUnitTask.java,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -r1.37 -r1.38
  --- JUnitTask.java	10 Feb 2002 01:01:12 -0000	1.37
  +++ JUnitTask.java	14 Feb 2002 09:34:27 -0000	1.38
  @@ -21,6 +21,7 @@
   import java.util.Random;
   import org.apache.aut.nativelib.ExecManager;
   import org.apache.myrmidon.api.TaskException;
  +import org.apache.myrmidon.api.TaskContext;
   import org.apache.tools.ant.Task;
   import org.apache.myrmidon.framework.Execute;
   import org.apache.tools.ant.taskdefs.exec.LogOutputStream;
  @@ -390,7 +391,8 @@
           while( list.hasNext() )
           {
               JUnitTest test = (JUnitTest)list.next();
  -            if( test.shouldRun( null ) )
  +            final TaskContext context = getContext();
  +            if( test.shouldRun( context ) )
               {
                   execute( test );
               }
  
  
  

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message