Coverage Report - org.apache.maven.surefire.failsafe.model.FailsafeSummary
 
Classes in this File Line Coverage Branch Coverage Complexity
FailsafeSummary
0%
0/31
0%
0/14
2.429
 
 1  
 /*
 2  
  =================== DO NOT EDIT THIS FILE ====================
 3  
  Generated by Modello 1.0.1 on 2010-08-10 11:25:55,
 4  
  any modifications will be overwritten.
 5  
  ==============================================================
 6  
  */
 7  
 
 8  
 package org.apache.maven.surefire.failsafe.model;
 9  
 
 10  
 /**
 11  
  * 
 12  
  *         Describes the results of executing tests
 13  
  *       .
 14  
  * 
 15  
  * @version $Revision$ $Date$
 16  
  */
 17  0
 public class FailsafeSummary
 18  
     implements java.io.Serializable
 19  
 {
 20  
 
 21  
       //--------------------------/
 22  
      //- Class/Member Variables -/
 23  
     //--------------------------/
 24  
 
 25  
     /**
 26  
      * The surefire result code.
 27  
      */
 28  0
     private int result = 0;
 29  
 
 30  
     /**
 31  
      * The exception that caused surefire to bomb out.
 32  
      */
 33  
     private String exception;
 34  
 
 35  
     /**
 36  
      * Field modelEncoding.
 37  
      */
 38  0
     private String modelEncoding = "UTF-8";
 39  
 
 40  
 
 41  
       //-----------/
 42  
      //- Methods -/
 43  
     //-----------/
 44  
 
 45  
     /**
 46  
      * Get the exception that caused surefire to bomb out.
 47  
      * 
 48  
      * @return String
 49  
      */
 50  
     public String getException()
 51  
     {
 52  0
         return this.exception;
 53  
     } //-- String getException()
 54  
 
 55  
     /**
 56  
      * Method getModelEncoding.
 57  
      * 
 58  
      * @return the current encoding used when reading/writing this
 59  
      * model
 60  
      */
 61  
     public String getModelEncoding()
 62  
     {
 63  0
         return modelEncoding;
 64  
     } //-- String getModelEncoding()
 65  
 
 66  
     /**
 67  
      * Get the surefire result code.
 68  
      * 
 69  
      * @return int
 70  
      */
 71  
     public int getResult()
 72  
     {
 73  0
         return this.result;
 74  
     } //-- int getResult()
 75  
 
 76  
     /**
 77  
      * Set the exception that caused surefire to bomb out.
 78  
      * 
 79  
      * @param exception
 80  
      */
 81  
     public void setException( String exception )
 82  
     {
 83  0
         this.exception = exception;
 84  0
     } //-- void setException( String )
 85  
 
 86  
     /**
 87  
      * Set an encoding used for reading/writing the model.
 88  
      * 
 89  
      * @param modelEncoding
 90  
      */
 91  
     public void setModelEncoding( String modelEncoding )
 92  
     {
 93  0
         this.modelEncoding = modelEncoding;
 94  0
     } //-- void setModelEncoding( String )
 95  
 
 96  
     /**
 97  
      * Set the surefire result code.
 98  
      * 
 99  
      * @param result
 100  
      */
 101  
     public void setResult( int result )
 102  
     {
 103  0
         this.result = result;
 104  0
     } //-- void setResult( int )
 105  
 
 106  
 
 107  
     /**
 108  
      * Merges the summary result with this summary result.
 109  
      *
 110  
      * @param summary The summary to merge.
 111  
      * @since 2.6
 112  
      */
 113  
     public void merge( FailsafeSummary summary )
 114  
     {
 115  0
         switch ( this.result )
 116  
         {
 117  
             case org.apache.maven.surefire.booter.SurefireBooter.TESTS_SUCCEEDED_EXIT_CODE:
 118  0
                 this.result = summary.result;
 119  0
                 break;
 120  
             case org.apache.maven.surefire.booter.SurefireBooter.NO_TESTS_EXIT_CODE:
 121  0
                 switch ( summary.result )
 122  
                 {
 123  
                     case org.apache.maven.surefire.booter.SurefireBooter.TESTS_SUCCEEDED_EXIT_CODE:
 124  0
                         break;
 125  
                     case org.apache.maven.surefire.booter.SurefireBooter.NO_TESTS_EXIT_CODE:
 126  0
                         break;
 127  
                     case org.apache.maven.surefire.booter.SurefireBooter.TESTS_FAILED_EXIT_CODE:
 128  0
                         this.result = summary.result;
 129  0
                         break;
 130  
                     default:
 131  0
                         this.result = summary.result;
 132  0
                         break;
 133  
                 }
 134  
                 break;
 135  
             case org.apache.maven.surefire.booter.SurefireBooter.TESTS_FAILED_EXIT_CODE:
 136  0
                 switch ( summary.result )
 137  
                 {
 138  
                     case org.apache.maven.surefire.booter.SurefireBooter.TESTS_SUCCEEDED_EXIT_CODE:
 139  0
                         break;
 140  
                     case org.apache.maven.surefire.booter.SurefireBooter.NO_TESTS_EXIT_CODE:
 141  0
                         break;
 142  
                     case org.apache.maven.surefire.booter.SurefireBooter.TESTS_FAILED_EXIT_CODE:
 143  0
                         break;
 144  
                     default:
 145  0
                         this.result = summary.result;
 146  0
                         break;
 147  
                 }
 148  
                 break;
 149  
             default:
 150  
                 break;
 151  
         }
 152  0
         if ( this.exception == null )
 153  
         {
 154  0
             this.exception = summary.exception;
 155  
         }
 156  0
     }
 157  
           
 158  
 }