Class StoryMerger

java.lang.Object
net.tangly.bdd.engine.StoryMerger

public class StoryMerger
extends java.lang.Object
Merges a set of JSON files produced through the execution of BDD JUnit tests. A feature is part of exactly one package. Therefore, the package name is the key to the feature. A story is part of exactly one class. Therefore, the class name is the key for the story. A scenario is part of exactly one method.
  • Constructor Summary

    Constructors 
    Constructor Description
    StoryMerger()  
  • Method Summary

    Modifier and Type Method Description
    void merge​(@NotNull java.nio.file.Path directory)
    Merges all BDD reports in the given directory into one file.
    void write​(java.nio.file.Path path)
    Writes the features to the provided file.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • merge

      public void merge​(@NotNull @NotNull java.nio.file.Path directory) throws java.io.IOException
      Merges all BDD reports in the given directory into one file.
      Parameters:
      directory - directory containing all feature reports to merge
      Throws:
      java.io.IOException - if access to the file system encountered a problem
    • write

      public void write​(java.nio.file.Path path)
      Writes the features to the provided file.
      Parameters:
      path - path of the file where the features will be written to