Coverage Report - org.jbehave.core.model.Lifecycle
 
Classes in this File Line Coverage Branch Coverage Complexity
Lifecycle
100%
11/11
50%
1/2
1
 
 1  
 package org.jbehave.core.model;
 2  
 
 3  
 import java.util.Arrays;
 4  
 import java.util.List;
 5  
 
 6  
 import org.apache.commons.lang.builder.ToStringBuilder;
 7  
 import org.apache.commons.lang.builder.ToStringStyle;
 8  
 
 9  
 public class Lifecycle {
 10  
 
 11  1
     public static final Lifecycle EMPTY = new Lifecycle();
 12  
 
 13  
     private List<String> beforeSteps;
 14  
     private List<String> afterSteps;
 15  
 
 16  
     public Lifecycle() {
 17  1
         this(Arrays.<String>asList(), Arrays.<String>asList());
 18  1
     }
 19  
 
 20  5
     public Lifecycle(List<String> beforeSteps, List<String> afterSteps) {
 21  5
         this.beforeSteps = beforeSteps;
 22  5
         this.afterSteps = afterSteps;
 23  5
     }
 24  
 
 25  
     public List<String> getBeforeSteps() {
 26  9
         return beforeSteps;
 27  
     }
 28  
 
 29  
     public List<String> getAfterSteps() {
 30  8
         return afterSteps;
 31  
     }
 32  
 
 33  
     public boolean isEmpty() {
 34  8
         return EMPTY == this;
 35  
     }
 36  
 
 37  
     @Override
 38  
     public String toString() {
 39  6
         return ToStringBuilder.reflectionToString(this, ToStringStyle.SHORT_PREFIX_STYLE);
 40  
     }
 41  
 
 42  
 }