thoughtbot/fishery

How to use rewind sequence

Closed this issue · 2 comments

Hello, could you please update the readme with an example how to use the rewindSequence()? In my usecase I would need the sequence rewinded after the factory is built, so the next call starts it from beginning.

Hello. There is some information in the readme about this, here. You can rewind the sequence anytime like this:

factory.build()
factory.rewindSequence()
factory.build() // sequence reset back to initial value

Let me know if you still have any questions.

Closing issue since a suggestion has been provided, and there has been no recent activity.