org.jbehave.core
Class PropertyBasedStoryConfiguration

java.lang.Object
  extended by org.jbehave.core.StoryConfiguration
      extended by org.jbehave.core.PropertyBasedStoryConfiguration

public class PropertyBasedStoryConfiguration
extends StoryConfiguration

PropertyBasedStoryConfiguration is backed by MostUsefulStoryConfiguration as default, but has different behaviour if certain system properties are non-null:


Field Summary
static java.lang.String FAIL_ON_PENDING
           
static java.lang.String OUTPUT_ALL
           
 
Constructor Summary
PropertyBasedStoryConfiguration()
           
PropertyBasedStoryConfiguration(StoryConfiguration defaultConfiguration)
           
 
Method Summary
 ErrorStrategy errorStrategy()
          Returns the default ErrorStrategy for handling errors.
 Keywords keywords()
          Returns the default keywords.
 PendingErrorStrategy pendingErrorStrategy()
          If the system property org.jbehave.failonpending is non-null, returns PendingStepStrategy.FAILING, otherwise returns the defaults.
 StepCreator stepCreator()
          Returns the default StepCreator.
 StepdocGenerator stepdocGenerator()
           
 StepdocReporter stepdocReporter()
           
 StoryParser storyParser()
          Returns the default StoryParser.
 StoryReporter storyReporter()
          If the system property org.jbehave.outputall is set to TRUE, uses a PrintStreamStoryReporter; otherwise uses the default StoryReporter.
 
Methods inherited from class org.jbehave.core.StoryConfiguration
buildReporters, buildReporters, storyLoader, storyPathResolver, storyReporter, storyReporterBuilder, useErrorStrategy, useKeywords, usePendingErrorStrategy, useStepCreator, useStepdocGenerator, useStepdocReporter, useStoryLoader, useStoryParser, useStoryPathResolver, useStoryReporter, useStoryReporter, useStoryReporterBuilder, useStoryReporters
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

FAIL_ON_PENDING

public static final java.lang.String FAIL_ON_PENDING
See Also:
Constant Field Values

OUTPUT_ALL

public static final java.lang.String OUTPUT_ALL
See Also:
Constant Field Values
Constructor Detail

PropertyBasedStoryConfiguration

public PropertyBasedStoryConfiguration()

PropertyBasedStoryConfiguration

public PropertyBasedStoryConfiguration(StoryConfiguration defaultConfiguration)
Method Detail

storyReporter

public StoryReporter storyReporter()
If the system property org.jbehave.outputall is set to TRUE, uses a PrintStreamStoryReporter; otherwise uses the default StoryReporter. Setting org.jbehave.outputall will allow you to see the steps for all stories, regardless of whether the stories fail.

Overrides:
storyReporter in class StoryConfiguration

storyParser

public StoryParser storyParser()
Returns the default StoryParser.

Overrides:
storyParser in class StoryConfiguration

pendingErrorStrategy

public PendingErrorStrategy pendingErrorStrategy()
If the system property org.jbehave.failonpending is non-null, returns PendingStepStrategy.FAILING, otherwise returns the defaults.

Setting org.jbehave.failonpending will cause pending steps to throw an error, so you can see if any steps don't match or are still to be implemented.

Overrides:
pendingErrorStrategy in class StoryConfiguration

stepCreator

public StepCreator stepCreator()
Returns the default StepCreator.

Overrides:
stepCreator in class StoryConfiguration

errorStrategy

public ErrorStrategy errorStrategy()
Returns the default ErrorStrategy for handling errors.

Overrides:
errorStrategy in class StoryConfiguration

keywords

public Keywords keywords()
Returns the default keywords.

Overrides:
keywords in class StoryConfiguration

stepdocGenerator

public StepdocGenerator stepdocGenerator()
Overrides:
stepdocGenerator in class StoryConfiguration

stepdocReporter

public StepdocReporter stepdocReporter()
Overrides:
stepdocReporter in class StoryConfiguration


Copyright © 2003-2010. All Rights Reserved.