Skip to content

Latest commit

 

History

History
60 lines (46 loc) · 1.44 KB

File metadata and controls

60 lines (46 loc) · 1.44 KB

StoryBoard

Contents

How to verify sequences

StoryBoards can be very helpful to tell a story of steps that happen over time. Here is a simple example

Approvals.verify(new StoryBoard().add(gameOfLife).addFrames(3, gameOfLife::advance));

snippet source | anchor

which produces

Initial:
.  .  .  .  .  
.  .  .  .  .  
.  x  x  x  .  
.  .  .  .  .  
.  .  .  .  .  


Frame #1:
.  .  .  .  .  
.  .  x  .  .  
.  .  x  .  .  
.  .  x  .  .  
.  .  .  .  .  


Frame #2:
.  .  .  .  .  
.  .  .  .  .  
.  x  x  x  .  
.  .  .  .  .  
.  .  .  .  .  


Frame #3:
.  .  .  .  .  
.  .  x  .  .  
.  .  x  .  .  
.  .  x  .  .  
.  .  .  .  .

snippet source | anchor